diff --git a/PKGBUILD b/PKGBUILD index 7cf0b29..e521b91 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -25,9 +25,9 @@ package() { install -Dm755 ${srcdir}/bin/periodic/* ${pkgdir}/usr/bin # copy systemd units - install -d ${pkgdir}/usr/lib/systemd/system - install -Dm644 ${srcdir}/systemd/services/* ${pkgdir}/usr/lib/systemd/system - install -Dm644 ${srcdir}/systemd/timers/* ${pkgdir}/usr/lib/systemd/system + install -d ${pkgdir}/usr/lib/systemd/user + install -Dm644 ${srcdir}/systemd/services/* ${pkgdir}/usr/lib/systemd/user + install -Dm644 ${srcdir}/systemd/timers/* ${pkgdir}/usr/lib/systemd/user # copy alpm hooks install -d ${pkgdir}/usr/share/libalpm/hooks diff --git a/fixes-package.install b/fixes-package.install index 7029b8d..455226c 100644 --- a/fixes-package.install +++ b/fixes-package.install @@ -1,4 +1,9 @@ post_install() { - find /usr/lib/systemd/system/ -name "fix-*.timer" -type f -print0 | xargs -0 systemctl enable - find /usr/lib/systemd/system/ -name "fix-*.timer" -type f -print0 | xargs -0 systemctl start + find /usr/lib/systemd/user/ -name "fix-*.timer" -type f -print0 | xargs -0 systemctl --user enable + find /usr/lib/systemd/user/ -name "fix-*.timer" -type f -print0 | xargs -0 systemctl --user start +} + +post_upgrade() { + find /usr/lib/systemd/user/ -name "fix-*.timer" -type f -print0 | xargs -0 systemctl --user enable + find /usr/lib/systemd/user/ -name "fix-*.timer" -type f -print0 | xargs -0 systemctl --user restart }