diff options
| author | Craig Jennings <c@cjennings.net> | 2026-06-10 16:35:26 -0500 |
|---|---|---|
| committer | Craig Jennings <c@cjennings.net> | 2026-06-10 16:35:26 -0500 |
| commit | 686553eb0998d05d3fbb48963c9397fb587b5f9e (patch) | |
| tree | a4b8a7bab5a8378ca6080f2aada7d25d96e21284 | |
| parent | b242713ec74e6b0decd619b8bd12a207aab0ac16 (diff) | |
| download | archsetup-686553eb0998d05d3fbb48963c9397fb587b5f9e.tar.gz archsetup-686553eb0998d05d3fbb48963c9397fb587b5f9e.zip | |
fix(testing): expect minimal/ tree for the .zshrc symlink on DESKTOP_ENV=none
The dotfiles validation hardcoded .dotfiles/common/.zshrc, but a none install stows the standalone minimal/ tree, so the first none-run ever to reach validation failed on a correct symlink. The expected path now follows DESKTOP_ENV from the VM conf.
| -rw-r--r-- | scripts/testing/lib/validation.sh | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/scripts/testing/lib/validation.sh b/scripts/testing/lib/validation.sh index d81332b..c705419 100644 --- a/scripts/testing/lib/validation.sh +++ b/scripts/testing/lib/validation.sh @@ -369,10 +369,13 @@ validate_dotfiles() { fi # 2. Check symlink points to correct location. archsetup now clones the - # dotfiles repo to ~/.dotfiles and stows from there (DOTFILES_DIR default), - # so the link resolves to .dotfiles/common/.zshrc, not the old in-repo path. + # dotfiles repo to ~/.dotfiles and stows from there (DOTFILES_DIR default). + # Which tree owns .zshrc depends on DESKTOP_ENV: none stows the standalone + # minimal/ tree; dwm and hyprland stow common/. local target=$(ssh_cmd "readlink /home/cjennings/.zshrc") + local desktop_env=$(sed -n 's/^DESKTOP_ENV=//p' "$ARCHSETUP_VM_CONF" 2>/dev/null | head -n1) local expected_pattern=".dotfiles/common/.zshrc" + [ "$desktop_env" = "none" ] && expected_pattern=".dotfiles/minimal/.zshrc" if ! echo "$target" | grep -q "$expected_pattern"; then validation_fail "Dotfiles symlink points to wrong location: $target" |
