diff options
Diffstat (limited to 'home-configuration.scm')
-rw-r--r-- | home-configuration.scm | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/home-configuration.scm b/home-configuration.scm index fa266f90..74abf75d 100644 --- a/home-configuration.scm +++ b/home-configuration.scm @@ -48,6 +48,10 @@ ;; relative to the working directory, not this file's directory. #.(define catppuccin-theme-variant "mocha") +;; "Base" colour from the active Catppuccin theme (see +;; https://github.com/catppuccin/catppuccin). +(define catppuccin-background-color "1e1e2e") + (define* (package-binary specification #:optional (binary specification)) "Get the path of BINARY inside the package referred to by SPECIFICATION." (file-append (specification->package specification) @@ -318,6 +322,17 @@ replacement spec (to which `regexp-substitute/global' is applied)." (".local/bin/icat" ; kitty's "catimg" equivalent ,(program-file "icat" #~(apply execl #$(package-binary "kitty") "kitty" "+kitten" "icat" (cdr (command-line))))) + (".local/bin/screenlock" + ,(program-file + "screenlock" + #~(begin ; Wrapper around i3lock to turn off the screen and pause notifications. + (system* #$(package-binary "dunst" "dunstctl") "set-paused" "true") + (system* #$(package-binary "xset") "dpms" "0" "0" "5") + ;; We mustn't use `package-binary' here, as we have to pick up the + ;; setuid binary for i3lock installed by the system config. + (system* "i3lock" "-nc" #$catppuccin-background-color) + (system* #$(package-binary "xset") "dpms" "0" "0" "0") + (system* #$(package-binary "dunst" "dunstctl") "set-paused" "false")))) ;; With #:recursive? #t, Guix keeps the files' permission bits, i.e. makes them executable. (".local/bin/sessionmenu" ,(local-file "sessionmenu" #:recursive? #t)) ; rofi logout/reboot menu (".local/bin/passmenu" ,(local-file "passmenu" #:recursive? #t)) ; rofi passwords menu |