Skip to content

l1asis/winspot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

70 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

winspot

winspot is a Python utility and command-line tool to export, reset, and download Windows Spotlight images. Additionally, it can download Bing's daily images.

Installation

Install directly from PyPI using pip or pipx:

pip install winspot
# or
pipx install winspot

Or install the latest version from source:

git clone https://github.com/l1asis/winspot.git
cd winspot
pip install .

If you want to download Bing/Spotlight images, make sure to install the optional dependencies:

pip install winspot[dl]
# or from source
pip install .[dl]

Usage

CLI

winspot uses subcommands to organize different operations:

Extract Windows Spotlight

# Save all images (cached, desktop, lockscreen)
winspot extract

# Save only cached images
winspot extract --cached

# Save only desktop image
winspot extract --desktop

# Save only lock screen image
winspot extract --lockscreen

# Save only landscape images with duplicate prevention
winspot extract --orientation landscape --prevent-duplicates

Download Spotlight Images

# Download images from Spotlight API
winspot download

# Download from both API versions (v3 and v4)
winspot download --api-version both

# Download and organize by orientation or resolution
winspot download --orientation both --organize-by orientation
winspot download --orientation both --organize-by resolution

Download Bing Daily Images

# Download today's Bing image in 4K
winspot bing

# Download the last 7 days of images
winspot bing --count 7

# Download in 1080p with specific locale
winspot bing --resolution 1920x1080 --locale de-DE

Reset Windows Spotlight

# Reset with confirmation prompt
winspot --reset

# Force reset without confirmation
winspot --reset --force

For complete help:

winspot --help
winspot extract --help
winspot bing --help

As a Library

import winspot

# Save with default settings (all sources)
winspot.extract_images()

# Save only cached images
winspot.extract_images(desktop=False, lockscreen=False)

# Save only landscape images with duplicate prevention
winspot.extract_images(
    orientation="landscape",
    prevent_duplicates=True
)

# Save with conflict resolution
winspot.extract_images(
    on_conflict="skip",  # or "overwrite", "rename"
)

# Download Spotlight API images
winspot.download_images(
    orientation="landscape",
    organize_by="resolution",
    prevent_duplicates=True
)

# Download Bing daily images
winspot.download_bing_daily_images(
    count=7,
    resolution="3840x2160",
    locale="en-US",
    prevent_duplicates=True
)

# Reset Windows Spotlight settings
winspot.reset_windows_spotlight()

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Acknowledgments

  • Thanks to Paulo Scardine for the get_image_size.py script used in this project.

License

Distributed under the MIT License. See LICENSE for more information.