個人 GitHub 帳號下公開儲存庫的擁有者可以登入並驗證所有權,自行管理介紹,無需管理員核准。
登入並產生驗證檔案,在 30 分鐘內將其提交至此儲存庫的預設分支。其他分支或分叉儲存庫中的檔案無效。然後在下方檢查檔案,即可無需管理員核准直接管理專案。請保留檔案以維持管理權限。
如需登入,將前往登入頁面。登入後請回到此處,再次點擊所選的驗證按鈕。
在專案資料夾中執行 /nomorevibe verify,即可驗證所有權並自行管理介紹。
一分鐘完成驗證One-click caffeinate for macOS: keep your Mac awake indefinitely or on a timer. Lightweight Swift menu bar app.
翻譯準備中
取自儲存庫 README
正在載入完整 README。
檢視完整 README ↗A tiny open-source menu bar app for Apple Silicon Macs that keeps your Mac awake, like caffeinate -d with an on/off switch and a timer.
Website: https://mpalarya.github.io/Awake/
arm64) only, macOS 15 Sequoia or laterbrew tap mpalarya/awake https://github.com/MPalarya/Awake
brew trust mpalarya/awake
brew install --cask awake
Homebrew 7 and later require you to trust a third-party tap before installing from it (brew trust).
To upgrade, run brew upgrade (the cask is bumped automatically on every release). To remove it, run brew uninstall --cask awake.
curl -fsSL https://raw.githubusercontent.com/MPalarya/Awake/main/install.sh | bash
This downloads the latest release, installs it into /Applications and launches it. Run the same command again to update.
Both methods skip the Gatekeeper warning described below.
Awake.dmg from the latest release.Release builds are ad-hoc signed but not notarized by Apple, so macOS blocks them the first time you open them.
Awake.app. When the warning appears, click Done.Or, from Terminal:
xattr -dr com.apple.quarantine /Applications/Awake.app
Click the cup icon in the menu bar. It is filled while Awake is on and outlined while it is off.
| Item | What it does |
|---|---|
| Keep Awake | Turns Awake on or off. |
| Until 14:30 | Shown during a timed session. Awake turns itself off at this time. |
| Duration | Indefinitely (the default), 15 or 30 minutes, or 1, 2, 4 or 8 hours. Choosing a duration also turns Awake on. If Awake is already on, the countdown restarts. Your choice is remembered. |
| Launch at Login | Registers the app with SMAppService.mainApp. |
| Quit Awake | Quits the app and lets your Mac sleep normally again. |
If you quit while Awake is on with Indefinitely selected, it turns back on the next time it launches. This lets Launch at Login keep your Mac awake permanently. Timed sessions don't resume.
While Awake is on, the display and the system don't go to sleep when idle. You can still sleep the Mac from the Apple menu. Closing the lid of a MacBook still puts it to sleep unless it is connected to power and an external display (clamshell mode), just like caffeinate.
To check that it's working:
pmset -g assertions | grep Awake
Everything is logged with os.Logger (subsystem com.awake.app):
log stream --predicate 'subsystem == "com.awake.app"'
You need Xcode 16+ or the Command Line Tools on an Apple Silicon Mac.
swift build -c release --arch arm64 # just the binary
scripts/build_app.sh # -> build/Awake.app (ad-hoc signed)
scripts/make_dmg.sh # -> build/Awake.dmg
VERSION=1.2.3 scripts/build_app.sh sets the bundle version. CODESIGN_IDENTITY="Developer ID Application: …" signs with a real identity instead of ad-hoc.
Push a tag that starts with v:
git tag v1.0.0 && git push origin v1.0.0
.github/workflows/release.yml then builds the arm64 app on a macos-15 runner, packages Awake.dmg, attaches it to a GitHub Release for that tag, and bumps Casks/awake.rb on main.
PowerAssertion.swift wraps IOPMAssertionCreateWithName with kIOPMAssertionTypePreventUserIdleDisplaySleep. This is the assertion caffeinate -d creates, and it also prevents idle system sleep. The kernel enforces it, and macOS releases it automatically if the app exits or crashes.AppDelegate.swift handles the menu bar UI and Launch at Login. A timed session arms a single Timer for its end time. Timers don't count time the Mac spends asleep, so the deadline is re-checked against the wall clock on NSWorkspace.didWakeNotification.MIT