42 lines
1.2 KiB
Scheme
42 lines
1.2 KiB
Scheme
|
(define-module (oni home services herbstluftwm)
|
||
|
#:use-module (gnu services configuration)
|
||
|
#:use-module (gnu packages wm)
|
||
|
#:use-module (gnu home services)
|
||
|
#:use-module (gnu home services utils)
|
||
|
#:use-module (guix packages)
|
||
|
#:use-module (guix gexp)
|
||
|
#:use-module (oni home services xsession)
|
||
|
|
||
|
#:export (home-herbstluftwm-service-type
|
||
|
home-herbstluftwm-configuration))
|
||
|
|
||
|
(define-configuration/no-serialization home-herbstluftwm-configuration
|
||
|
(package
|
||
|
(package herbstluftwm)
|
||
|
"Package use for setting herbstluftwm"))
|
||
|
|
||
|
(define (add-herbstluftwm-packages config)
|
||
|
(list (home-herbstluftwm-configuration-package config)))
|
||
|
|
||
|
(define (add-herbstluftwm-executable config)
|
||
|
(home-xsession-extension
|
||
|
(wm
|
||
|
(list
|
||
|
(mixed-text-file
|
||
|
"xsession"
|
||
|
"exec " herbstluftwm "/bin/herbstluftwm")))))
|
||
|
|
||
|
(define home-herbstluftwm-service-type
|
||
|
(service-type
|
||
|
(name 'home-herbstluftwm)
|
||
|
(extensions
|
||
|
(list (service-extension
|
||
|
home-profile-service-type
|
||
|
add-herbstluftwm-packages)
|
||
|
(service-extension
|
||
|
home-xsession-service-type
|
||
|
add-herbstluftwm-executable)))
|
||
|
(compose identity)
|
||
|
(default-value (home-herbstluftwm-configuration))
|
||
|
(description "Install and configure herbstluftwm.")))
|