From 6c18def51ea26faca6becc9256f135a84e13919b Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Sat, 29 Apr 2017 23:16:05 -0400 Subject: [PATCH] os/+arch (pacman): add polybar hook + update lemonbar hook --- os/+arch/install | 6 ++++++ os/+arch/pacman.d/hooks/lemonbar.hook | 2 +- os/+arch/pacman.d/hooks/polybar.hook | 12 ++++++++++++ 3 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 os/+arch/pacman.d/hooks/polybar.hook diff --git a/os/+arch/install b/os/+arch/install index 1d1d6ae6..e5b1f803 100755 --- a/os/+arch/install +++ b/os/+arch/install @@ -62,4 +62,10 @@ if [[ -z $SERVER ]]; then redshift firefox \ alsa-utils \ dictd dict-gcide + + hookdest=/etc/pacman.d/hooks + sudo mkdir -p "$hookdest" + for hook in $PWD/$hookdest/*.hook; do + [[ -f $hookdest/${hook##*/} ]] || sudo ln -svf $hook $hookdest/ + done fi diff --git a/os/+arch/pacman.d/hooks/lemonbar.hook b/os/+arch/pacman.d/hooks/lemonbar.hook index dc8ac6b9..c886b9d3 100644 --- a/os/+arch/pacman.d/hooks/lemonbar.hook +++ b/os/+arch/pacman.d/hooks/lemonbar.hook @@ -6,7 +6,7 @@ Type=Package Target=* [Action] -Description="Updating lemonbar updates segemnt" +Description="Updating lemonbar" When=PostTransaction Exec="/home/hlissner/.config/panel/panel-pacman-hook" diff --git a/os/+arch/pacman.d/hooks/polybar.hook b/os/+arch/pacman.d/hooks/polybar.hook new file mode 100644 index 00000000..174f58f1 --- /dev/null +++ b/os/+arch/pacman.d/hooks/polybar.hook @@ -0,0 +1,12 @@ +[Trigger] +Operation=Install +Operation=Upgrade +Operation=Remove +Type=Package +Target=* + +[Action] +Description="Updating polybar" +When=PostTransaction +Exec="/usr/bin/polybar-msg hook pkg 1" +