diff --git a/PKGBUILD b/PKGBUILD index 4b7d67a042003de1c356ec250ce1696c1de533dc..9f0f42f5c21641ecc2f6b81620d9fd98be64eb70 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -14,7 +14,7 @@ conflicts=('archutils' 'kernel-reinstall') package() { cd "$startdir" - install -dm755 "$pkgdir"/usr/{share/licenses/$pkgname,bin,lib/munin/plugins} + install -dm755 "$pkgdir"/usr/{share/{licenses/$pkgname,libalpm/hooks},bin,lib/munin/plugins} # install legal stuff install -m644 COPYRIGHT LICENSE "$pkgdir/usr/share/licenses/$pkgname" # install binaries @@ -26,6 +26,8 @@ package() { # add shortcut, because i'm lazy ln -s checkservices "$pkgdir/usr/bin/cs" ln -s system-upgrade "$pkgdir/usr/bin/sup" + # add hooks + install -m644 systemd-daemon-reload.hook "$pkgdir/usr/share/libalpm/hooks/10-systemd-daemon-reload.hook" } # vim:set ts=2 sw=2 et: diff --git a/systemd-daemon-reload.hook b/systemd-daemon-reload.hook new file mode 100644 index 0000000000000000000000000000000000000000..8e87feafeb855c07e376cc7f8d89215d18a67253 --- /dev/null +++ b/systemd-daemon-reload.hook @@ -0,0 +1,12 @@ +[Trigger] +Operation = Install +Operation = Upgrade +Operation = Remove +Type = File +Target = *.service + +[Action] +Description = Reload of systemd units +Depends = systemd +When = PostTransaction +Exec = /usr/bin/systemctl daemon-reload