aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2022-10-30 18:37:16 -0300
committerEuAndreh <eu@euandre.org>2022-10-30 18:37:16 -0300
commit69697ca024f3bd13e1b3425b22a4db88ac6e2bfe (patch)
tree425b4c8def1b9aa9bd3725c098d55cbf3bef374c
parentetc/guix/home.scm: Remove "poweralertd" package from profile (diff)
downloaddotfiles-69697ca024f3bd13e1b3425b22a4db88ac6e2bfe.tar.gz
dotfiles-69697ca024f3bd13e1b3425b22a4db88ac6e2bfe.tar.xz
Replace greenclip with clipmenu
-rwxr-xr-xbin/menu4
-rw-r--r--etc/guix/home.scm32
-rw-r--r--etc/i3/config1
3 files changed, 33 insertions, 4 deletions
diff --git a/bin/menu b/bin/menu
index c389a2f..73091bd 100755
--- a/bin/menu
+++ b/bin/menu
@@ -122,7 +122,9 @@ case "$ACTION" in
fi
;;
clipboard)
- greenclip print | show 'clipboard' | copy
+ # For a potential improved version, see:
+ # https://github.com/cdown/clipmenu/pull/162
+ clipmenu -i -l 20 -fn Monospace-18 -p "$1:"
;;
yubikey)
CHOICE="$(ykman oath accounts list | show 'OTP')"
diff --git a/etc/guix/home.scm b/etc/guix/home.scm
index d66804e..102ad5a 100644
--- a/etc/guix/home.scm
+++ b/etc/guix/home.scm
@@ -21,6 +21,7 @@
(gnu packages tmux)
(gnu packages version-control)
(gnu packages video)
+ (gnu packages xdisorg)
(gnu services)
(guix build-system trivial)
(guix download)
@@ -209,6 +210,34 @@
#~(job "30 0 * * *" "cronjob x update AND upgrade")
#~(job "30 0 * * *" "cronjob backup -q cron")))
+(define (clipmenu-shepherd-services _config)
+ (list
+ (shepherd-service
+ (provision '(clipmenu))
+ (documentation
+ #"-
+ Shepherd service that manages clipmenu."#)
+ (start
+ #~(make-forkexec-constructor
+ (list #$(file-append clipmenu "/bin/clipmenud"))))
+ (stop #~(make-kill-destructor)))))
+
+(define clipmenu-service-type
+ (service-type
+ (name 'clipmenu)
+ (extensions
+ (list
+ (service-extension home-shepherd-service-type
+ clipmenu-shepherd-services)
+ (service-extension home-profile-service-type
+ (lambda _ (list clipmenu)))))
+ (default-value '())
+ (description
+ #"-
+ Service that runs clipmenu as a daemon under Shepherd.
+
+ It has no configuration."#)))
+
(define (poweralertd-shepherd-services _config)
(list
(shepherd-service
@@ -454,8 +483,6 @@
i3status
xmessage
dmenu
- clipmenu
- greenclip
httpd ;; for htpasswd
weechat
@@ -540,6 +567,7 @@
"/sh/cronjob.sh"))))))
(services
(list
+ (service clipmenu-service-type)
(service poweralertd-service-type)
(simple-service 'my-shell-profile home-shell-profile-service-type
(list (plain-file "my-profile" ". ~/.usr/etc/sh/rc")))
diff --git a/etc/i3/config b/etc/i3/config
index c906a1e..3c0b800 100644
--- a/etc/i3/config
+++ b/etc/i3/config
@@ -23,7 +23,6 @@ exec xss-lock --transfer-sleep-lock -- i3lock --nofork
exec nm-applet
exec blueman-applet
exec dunst
-exec greenclip daemon
# Use pactl to adjust volume in PulseAudio.
set $refresh_i3status killall -SIGUSR1 i3status