Skip to content

About

Refreshes background to Prevent freezing or partial reset.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

Repository files navigation

StayWallpaper

A small PowerShell tool for the long-running Windows bug where the desktop background goes blank after idle, sleep, or Spotlight cache failure.

It does what the other GitHub wallpaper apps do, plus Spotlight harvesting:

  1. Copy Windows Spotlight images out of hidden caches into real .jpg files.
  2. Mix those with your own picture folder.
  3. Set the desktop to a local Picture (not live Spotlight).
  4. Re-apply that picture on a timer and when the PC wakes from sleep.

Windows can keep downloading Spotlight in the background. This tool just stops trusting Explorer to keep the wallpaper painted.

How the other tools work (what we copied)

Project Idea we reused
Windows_Wallpaper_Changer SystemParametersInfo to set a file from a folder on a timer
WallpaperSlideshow Keep running after Explorer restart / monitor changes
Spotlight extractors Scan ContentDeliveryManager + IrisService caches, keep only real large images

Native Spotlight on the desktop is the fragile part. Native Spotlight on the lock screen can stay on so Windows still downloads new photos.

Setup

  1. Create a folder for your own pictures, e.g. C:\Wallpapers.
  2. Edit config.json:
{
  "Mode": "Both",
  "OwnPicsFolder": "C:\\Wallpapers",
  "LibraryFolder": "%USERPROFILE%\\Pictures\\StayWallpaper-Spotlight",
  "IntervalMinutes": 30,
  "Fit": "Fill"
}

Mode:

  • OwnPics — only your folder
  • Spotlight — only harvested Spotlight images
  • Both — mix them
  1. Double-click Install.bat.
  2. In Settings → Personalization → Background, leave it on Picture. StayWallpaper will overwrite the picture file as needed. Lock screen can stay on Windows Spotlight.

What Install.bat registers

  • StayWallpaper-Apply — every N minutes and at logon
  • StayWallpaper-Wake — System event Power-Troubleshooter ID 1 (resume from sleep)
  • StayWallpaper-Harvest — copy new Spotlight files every 6 hours

Files land in %LOCALAPPDATA%\StayWallpaper\.

Manual commands

powershell -ExecutionPolicy Bypass -File StayWallpaper.ps1 -Action Harvest
powershell -ExecutionPolicy Bypass -File StayWallpaper.ps1 -Action Apply
powershell -ExecutionPolicy Bypass -File StayWallpaper.ps1 -Action Restore
powershell -ExecutionPolicy Bypass -File StayWallpaper.ps1 -Action Status
powershell -ExecutionPolicy Bypass -File StayWallpaper.ps1 -Action Uninstall

Next.bat jumps to another image now.

Multi-PC

Copy the StayWallpaper folder to each PC, edit config.json, run Install.bat. No admin required.

Uninstall

Run Uninstall.bat. Harvested pictures stay in LibraryFolder unless you delete them.

About

Refreshes background to Prevent freezing or partial reset.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages