Skip to content

hechen/Swwwitch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Swwwitch

Swift 6 macOS 14+

A simple macOS menu bar utility with three toggles:

  • Dark Mode — switch system appearance via AppleScript
  • Hide Desktop Icons — toggle Finder's CreateDesktop preference
  • Caffeinate — keep your Mac awake

Plus a Launch at Login toggle powered by SMAppService.

Interface

Requirements

  • macOS 14 (Sonoma) or later
  • Xcode 16+ / Swift 6

Building

The project uses XcodeGen to generate the Xcode project:

brew install xcodegen   # if needed
xcodegen generate
open Swwwitch.xcodeproj

Or build from the command line:

xcodegen generate
xcodebuild -scheme Swwwitch -configuration Release build

How It Works

Feature Implementation
Dark Mode AppleScript → System Events
Hide Desktop Icons defaults write com.apple.finder CreateDesktop + killall Finder
Caffeinate /usr/bin/caffeinate process
Launch at Login SMAppService.mainApp (no helper app needed)

The app runs as a menu bar agent (LSUIElement) using SwiftUI's MenuBarExtra.

License

MIT

About

Swwwwich your switcher.

Topics

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages