diff options
-rw-r--r-- | .SRCINFO | 2 | ||||
-rw-r--r-- | PKGBUILD | 2 | ||||
-rw-r--r-- | psd.install | 14 |
3 files changed, 16 insertions, 2 deletions
@@ -1,7 +1,7 @@ pkgbase = profile-sync-daemon pkgdesc = Syncs browser profiles to tmpfs reducing SSD/HDD calls and speeding-up browsers. pkgver = 6.10 - pkgrel = 1 + pkgrel = 2 url = https://github.com/graysky2/profile-sync-daemon install = psd.install arch = any @@ -2,7 +2,7 @@ pkgname='profile-sync-daemon' pkgver=6.10 -pkgrel=1 +pkgrel=2 pkgdesc='Syncs browser profiles to tmpfs reducing SSD/HDD calls and speeding-up browsers.' arch=('any') url='https://github.com/graysky2/profile-sync-daemon' diff --git a/psd.install b/psd.install index 320fc0eaf530..0c28cb275cf5 100644 --- a/psd.install +++ b/psd.install @@ -64,6 +64,20 @@ pre_upgrade() { if [ $(vercmp $2 6.07) -lt 0 ]; then echo '-> Recommend that you diff /usr/share/psd/psd.conf against ~/.config/psd/psd.conf' fi + + # version 6.10 relocates pid file + if [ $(vercmp $2 6.10) -lt 0 ]; then + for i in $(users); do + running="$(su $i -s /bin/sh -c 'XDG_RUNTIME_DIR=/run/user/$UID systemctl --user is-active psd')" + if [[ "$running" = "active" ]]; then + su $i -s /bin/sh -c 'XDG_RUNTIME_DIR=/run/user/$UID systemctl --user stop psd.service' + su $i -s /bin/sh -c 'XDG_RUNTIME_DIR=/run/user/$UID systemctl --user daemon-reload' + echo '-> Internal changes to psd require it to be stopped now before updating.' + echo '-> Users of overlayfs: you must run the following before starting the service: psd p' + fi + done + fi + } pre_remove() { |