Last active
February 24, 2021 07:53
-
-
Save CRTified/708c01806ff0ab76954d4aed9a1182af to your computer and use it in GitHub Desktop.
Automatic recompilation after xmonad or haskell libs update
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Trigger] | |
Operation=Install | |
Operation=Upgrade | |
Type=Package | |
Target=xmonad | |
Target=haskell-* | |
[Action] | |
Depends=xmonad | |
When=PostTransaction | |
Exec=/bin/sh -c 'awk -F : "{print \$1\" \"\$6}" /etc/passwd | while IFS=" " read -r l_name l_dir ; do if [ -f "${l_dir}/.xmonad/xmonad.hs" ]; then echo Recompiling xmonad for $l_name; sudo -n -u $l_name xmonad --recompile; fi; done' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment