summaryrefslogtreecommitdiff
path: root/archsetup
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2026-01-19 10:27:00 -0600
committerCraig Jennings <c@cjennings.net>2026-01-19 10:27:00 -0600
commitd1a76db1cfadad63d120ff1bcbc4c6e29faaaff0 (patch)
tree9c3ba8faf8304ff4bb4ed8b6158b69a238095d36 /archsetup
parent978f8118a44b8fd616b6753f6bee0e3133a5e439 (diff)
fix(archsetup): fix ZFS scrub timer and emacs clone
- ZFS scrub timer: use template unit with pool name (zfs-scrub-weekly@pool.timer) - Emacs config: handle existing .emacs.d dir with git pull instead of failing
Diffstat (limited to 'archsetup')
-rwxr-xr-xarchsetup14
1 files changed, 11 insertions, 3 deletions
diff --git a/archsetup b/archsetup
index df0e6b7..34e8ed5 100755
--- a/archsetup
+++ b/archsetup
@@ -1062,7 +1062,9 @@ EOF
systemctl enable sanoid.timer >> "$logfile" 2>&1 || error "error" "$action" "$?"
action="enabling weekly ZFS scrub" && display "task" "$action"
- systemctl enable zfs-scrub-weekly.timer >> "$logfile" 2>&1 || error "error" "$action" "$?"
+ # Get pool name dynamically (usually zroot)
+ zfs_pool=$(zpool list -H -o name | head -1)
+ systemctl enable "zfs-scrub-weekly@${zfs_pool}.timer" >> "$logfile" 2>&1 || error "error" "$action" "$?"
# Note: zfs-replicate.timer is NOT enabled automatically
# User must set up SSH key auth to TrueNAS first, then run:
@@ -1410,8 +1412,14 @@ developer_workstation () {
pacman_install yt-dlp # video download
action="setting up emacs configuration files" && display "task" "$action"
- (sudo -u "$username" git clone --recurse-submodules "$dotemacs_repo" "/home/$username/.emacs.d" >> \
- "$logfile" 2>&1) || error "error" "$action" "$?"
+ emacs_dir="/home/$username/.emacs.d"
+ if [ -d "$emacs_dir" ]; then
+ (cd "$emacs_dir" && sudo -u "$username" git pull --recurse-submodules >> "$logfile" 2>&1) || \
+ error "error" "$action" "$?"
+ else
+ (sudo -u "$username" git clone --recurse-submodules "$dotemacs_repo" "$emacs_dir" >> \
+ "$logfile" 2>&1) || error "error" "$action" "$?"
+ fi
action="Android Utilities" && display "subtitle" "$action"
pacman_install android-file-transfer