From 28ff76fc03d75b1e5360f4dfce0b5918270073a2 Mon Sep 17 00:00:00 2001 From: Tom Willemse Date: Thu, 27 Jul 2023 23:17:45 -0700 Subject: Add stumptray to stumpwm configuration --- oni/home/config/rincewind.scm | 10 +++++++++- oni/home/services/stumpwm.scm | 37 +++++++++++++++++++++++++++++++++++-- 2 files changed, 44 insertions(+), 3 deletions(-) (limited to 'oni') diff --git a/oni/home/config/rincewind.scm b/oni/home/config/rincewind.scm index 08a92e6..fcaa67b 100644 --- a/oni/home/config/rincewind.scm +++ b/oni/home/config/rincewind.scm @@ -96,7 +96,9 @@ #:select (home-stumpwm-service-type home-stumpwm-configuration home-stumpwm-gaps-service-type - home-stumpwm-gaps-configuration)) + home-stumpwm-gaps-configuration + home-stumpwm-stumptray-service-type + home-stumpwm-stumptray-configuration)) #:use-module ((oni home services syncthing) #:select (home-syncthing-service-type)) #:use-module ((oni home services utilities) @@ -344,6 +346,12 @@ (home-stumpwm-gaps-configuration (configurations (list (local-file "../services/stumpwm/config-gaps"))))) + (service home-stumpwm-stumptray-service-type + (home-stumpwm-stumptray-configuration + (configurations + (list (mixed-text-file "config-stumptray" + "(require 'stumptray)\n" + "(stumptray::stumptray)\n"))))) (service home-inkplate-display-service-type) (service home-notmuch-service-type diff --git a/oni/home/services/stumpwm.scm b/oni/home/services/stumpwm.scm index 66db596..ad66106 100644 --- a/oni/home/services/stumpwm.scm +++ b/oni/home/services/stumpwm.scm @@ -11,7 +11,8 @@ #:use-module ((gnu packages wm) #:select (stumpwm stumpish - sbcl-stumpwm-swm-gaps)) + sbcl-stumpwm-swm-gaps + sbcl-stumpwm-stumptray)) #:use-module ((gnu home services) #:select (service-type service-extension @@ -31,7 +32,10 @@ home-stumpwm-extension home-stumpwm-gaps-service-type - home-stumpwm-gaps-configuration)) + home-stumpwm-gaps-configuration + + home-stumpwm-stumptray-service-type + home-stumpwm-stumptray-configuration)) (define-configuration/no-serialization home-stumpwm-extension (configurations @@ -118,3 +122,32 @@ (compose identity) (default-value (home-stumpwm-gaps-configuration)) (description "Install and configure stumpwm-gaps."))) + +(define-configuration/no-serialization home-stumpwm-stumptray-configuration + (package + (package sbcl-stumpwm-stumptray) + "Package to use for setting stumpwm-stumptray.") + (configurations + (text-config '()) + "Configuration for stumpwm gaps")) + +(define (add-stumpwm-stumptray config) + (home-stumpwm-extension + (configurations (home-stumpwm-stumptray-configuration-configurations config)))) + +(define (add-stumpwm-stumptray-packages config) + (list (home-stumpwm-stumptray-configuration-package config))) + +(define home-stumpwm-stumptray-service-type + (service-type + (name 'home-stumpwm-stumptray) + (extensions + (list (service-extension + home-stumpwm-service-type + add-stumpwm-stumptray) + (service-extension + home-profile-service-type + add-stumpwm-stumptray-packages))) + (compose identity) + (default-value (home-stumpwm-stumptray-configuration)) + (description "Install and configure stumpwm-stumptray."))) -- cgit v1.2.3-54-g00ecf