Skip to content

Repository files navigation

BlackScreen

BlackScreen is a native macOS screen saver that does the minimum possible work: it immediately transitions to the saver, paints an opaque black view, and stretches the animation interval to one day so the framework does not keep waking up to animate frames.

The result is a small Apple Silicon .saver bundle written in Swift with no configuration UI, no assets, and no rendering loop beyond the initial black fill.

Requirements

  • macOS 13 or newer
  • Xcode Command Line Tools or Xcode with Swift 6.x
  • Apple Silicon (arm64) by default

Build

make build

That produces Build/BlackScreen.saver.

Test

make test

Run a single test with Swift Testing filtering:

swift test --filter BlackScreenCoreTests/randomizedRenderingStaysBlack

The test suite covers bundle metadata, animation interval normalization, and randomized render checks that instantiate the real ScreenSaverView subclass across many frame sizes to verify it stays black.

Install

make install

This copies the built bundle into ~/Library/Screen Savers/BlackScreen.saver. You can then select it in Screen Saver settings.

Verify the built bundle

file Build/BlackScreen.saver/Contents/MacOS/BlackScreen
otool -L Build/BlackScreen.saver/Contents/MacOS/BlackScreen

Project layout

  • Sources/BlackScreenCore/ contains the Swift metadata and ScreenSaverView subclass.
  • Tests/BlackScreenCoreTests/ contains automated and randomized validation.
  • Resources/Info.plist defines the bundle metadata copied into the .saver.
  • Scripts/build-saver.sh packages the .saver bundle and copies any needed Swift runtime libraries.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages