diff options
-rw-r--r-- | stumpwm.org | 22 |
1 files changed, 15 insertions, 7 deletions
diff --git a/stumpwm.org b/stumpwm.org index 9963808..33407c1 100644 --- a/stumpwm.org +++ b/stumpwm.org @@ -43,20 +43,28 @@ #+begin_src lisp (setf *wallpapers* "~/wallpapers/") - (defun feh-set-wallpaper (wallpaper-name) + "Set wallpaper using feh" (let ((wallpaper-dir "~/wallpapers/")) (format t "Setting wallpaper: ~a~%" wallpaper-name) - (run-shell-command (format nil "feh --bg-scale ~a~a" wallpaper-dir wallpaper-name)))) + (stumpwm:run-shell-command (format nil "feh --bg-scale ~a~a" wallpaper-dir wallpaper-name)))) + - (cond ((equal (asdf:hostname) "zeus") (feh-set-wallpaper "eris-chocolates.jpg")) - ((equal (asdf:hostname) "hermes") (feh-set-wallpaper "library-old-house.jpg"))) + (defun thanos/set-wallpapers () + "Set wallpapers depending on hostname." + (cond ((equal (asdf:hostname) "zeus") (feh-set-wallpaper "eris-chocolates.jpg")) + ((equal (asdf:hostname) "hermes") (feh-set-wallpaper "library-old-house.jpg")))) + (defun thanos/run-commands (input) + "Run a list of shell commands" + (mapc #'stumpwm:run-shell-command input)) (when *initializing* - (stumpwm:run-shell-command "emacs --daemon") - (stumpwm:run-shell-command "picom") - (stumpwm:run-shell-command "setxkbmap -layout us,gr,my-bg -option 'ctrl:swapcaps' -option 'grp:alt_space_toggle'")) + (thanos/run-commands + '("emacs --daemon" + "picom" + "setxkbmap -layout us,gr,my-bg -option 'ctrl:swapcaps' -option 'grp:alt_space_toggle'")) + (thanos/set-wallpapers)) (setf *startup-message* "Welcome back, Thanos") #+end_src |