mirror of
https://github.com/basecamp/omarchy.git
synced 2026-02-17 15:25:37 +00:00
Feature/screensaver toggle instead of launch (#784)
* sceensaver-toggle and run if enabled using state file * replace commands in menu and hyperidle * migration file * sed corrections * added backup of changed files in migration * review comments implemented * hypridle config restore * Use normal path style * Use nerdfont icon for notification * Make executable * Allow a force start of screensaver so it can run even when disabled when manually triggered * Add screensaver to system menu now that the toggle actually means toggle * Known path without expansion spaces * It should be an error return when it doesn't start --------- Co-authored-by: Manuel <manuel.ramsaier@gmail.com> Co-authored-by: David Heinemeier Hansson <david@hey.com>
This commit is contained in:
12
bin/omarchy-toggle-screensaver
Executable file
12
bin/omarchy-toggle-screensaver
Executable file
@@ -0,0 +1,12 @@
|
||||
#!/bin/bash
|
||||
|
||||
STATE_FILE=~/.local/state/omarchy/toggles/screensaver-off
|
||||
|
||||
if [[ -f $STATE_FILE ]]; then
|
||||
rm -f $STATE_FILE
|
||||
notify-send " Screensaver enabled"
|
||||
else
|
||||
mkdir -p "$(dirname $STATE_FILE)"
|
||||
touch $STATE_FILE
|
||||
notify-send " Screensaver disabled"
|
||||
fi
|
||||
Reference in New Issue
Block a user