summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-x.local/bin/arkenfox-auto-update5
1 files changed, 4 insertions, 1 deletions
diff --git a/.local/bin/arkenfox-auto-update b/.local/bin/arkenfox-auto-update
index 05f4ca7..7664a4f 100755
--- a/.local/bin/arkenfox-auto-update
+++ b/.local/bin/arkenfox-auto-update
@@ -16,5 +16,8 @@ IFS='
# Update each found profile.
for profile in $profiles; do
- arkenfox-updater -p "${profile%%/user.js*}" -s
+ userjs=${profile%%/user.js*}
+ user=$(stat -c '%U' "$userjs") || continue
+
+ su -l "$user" -c "arkenfox-updater -c -p $userjs -s"
done