Compare commits

..

9 Commits

Author SHA1 Message Date
eSh
a9a7ce9bad add restart message 2022-09-18 16:43:08 +02:00
eSh
41f2c45900 add daemon reload commands 2022-09-18 15:41:08 +02:00
eSh
69d5f3b3c1 use global level to change timer statuses 2022-09-18 15:28:39 +02:00
eSh
be2b24d26d use only filenames for post scripts 2022-09-18 15:12:36 +02:00
eSh
3b6e886667 move services and timers on user level 2022-09-18 15:12:36 +02:00
eSh
4ff7f7a0b3 start the timers right away 2022-09-18 15:12:36 +02:00
eSh
184bdec3c4 add more accuracy for timers 2022-09-18 15:12:36 +02:00
eSh
5e22263904 use xargs to enable systemd timers 2022-09-18 15:12:36 +02:00
eSh
9a62cf6bf1 add systemd timers for periodic fixes 2022-09-18 15:12:36 +02:00
5 changed files with 21 additions and 12 deletions

@ -1,6 +1,6 @@
# Maintainer: TROM <contact@tromsite.com> # Maintainer: TROM <contact@tromsite.com>
pkgname=tromjaro-fixes pkgname=tromjaro-fixes
pkgver=1.2.0 pkgver=1.1.1
pkgrel=1 pkgrel=1
pkgdesc="Various fixes for TROMjaro OS" pkgdesc="Various fixes for TROMjaro OS"
arch=(any) arch=(any)
@ -24,6 +24,11 @@ package() {
install -Dm755 ${srcdir}/bin/standalone/* ${pkgdir}/usr/bin install -Dm755 ${srcdir}/bin/standalone/* ${pkgdir}/usr/bin
install -Dm755 ${srcdir}/bin/periodic/* ${pkgdir}/usr/bin install -Dm755 ${srcdir}/bin/periodic/* ${pkgdir}/usr/bin
# copy systemd units
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 # copy alpm hooks
install -d ${pkgdir}/usr/share/libalpm/hooks install -d ${pkgdir}/usr/share/libalpm/hooks
install -Dm644 ${srcdir}/alpm-hooks/* ${pkgdir}/usr/share/libalpm/hooks install -Dm644 ${srcdir}/alpm-hooks/* ${pkgdir}/usr/share/libalpm/hooks
@ -31,9 +36,4 @@ package() {
# copy flatpak overrides # copy flatpak overrides
install -d ${pkgdir}/var/lib/flatpak/overrides install -d ${pkgdir}/var/lib/flatpak/overrides
install -Dm644 ${srcdir}/flatpak-overrides/* ${pkgdir}/var/lib/flatpak/overrides install -Dm644 ${srcdir}/flatpak-overrides/* ${pkgdir}/var/lib/flatpak/overrides
# copy systemd units
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
} }

@ -1,14 +1,23 @@
post_install() { post_install() {
systemctl --global daemon-reload
find /usr/lib/systemd/user/ -name "fix-*.timer" -type f -printf "%f\0" | xargs -0 systemctl --global enable find /usr/lib/systemd/user/ -name "fix-*.timer" -type f -printf "%f\0" | xargs -0 systemctl --global enable
echo "Warning: A restart is required to take effect" find /usr/lib/systemd/user/ -name "fix-*.timer" -type f -printf "%f\0" | xargs -0 systemctl --global start
echo "A restart is required for the changes to take effect"
} }
post_upgrade() { post_upgrade() {
systemctl --global daemon-reload
find /usr/lib/systemd/user/ -name "fix-*.timer" -type f -printf "%f\0" | xargs -0 systemctl --global enable find /usr/lib/systemd/user/ -name "fix-*.timer" -type f -printf "%f\0" | xargs -0 systemctl --global enable
echo "Warning: A restart is required to take effect" find /usr/lib/systemd/user/ -name "fix-*.timer" -type f -printf "%f\0" | xargs -0 systemctl --global restart
echo "A restart is required for the changes to take effect"
} }
pre_remove() { pre_remove() {
find /usr/lib/systemd/user/ -name "fix-*.timer" -type f -printf "%f\0" | xargs -0 systemctl --global stop
find /usr/lib/systemd/user/ -name "fix-*.timer" -type f -printf "%f\0" | xargs -0 systemctl --global disable find /usr/lib/systemd/user/ -name "fix-*.timer" -type f -printf "%f\0" | xargs -0 systemctl --global disable
echo "Warning: A restart is required to take effect" }
post_remove() {
systemctl --global daemon-reload
echo "A restart is required for the changes to take effect"
} }

@ -10,4 +10,4 @@ Type=oneshot
ExecStart=/usr/bin/fix-flatpaks-theming ExecStart=/usr/bin/fix-flatpaks-theming
[Install] [Install]
WantedBy=default.target WantedBy=multi-user.target

@ -10,4 +10,4 @@ Type=oneshot
ExecStart=/usr/bin/fix-theming ExecStart=/usr/bin/fix-theming
[Install] [Install]
WantedBy=default.target WantedBy=multi-user.target

@ -10,4 +10,4 @@ Type=oneshot
ExecStart=/usr/bin/fix-tweaked-desktop-files ExecStart=/usr/bin/fix-tweaked-desktop-files
[Install] [Install]
WantedBy=default.target WantedBy=multi-user.target