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 | 1754a945fa58fbdf71561596e5ddf06dea7428be (patch) | |
| tree | e62078fb35206e2067630c6a1d9db4680c31bc99 /scripts | |
| parent | 3a8d4d272901a862b6e4ecc1beada1abe7509b06 (diff) | |
| download | archsetup-1754a945fa58fbdf71561596e5ddf06dea7428be.tar.gz archsetup-1754a945fa58fbdf71561596e5ddf06dea7428be.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.
Diffstat (limited to 'scripts')
| -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" |
