fix(deploy): override packages target home-relative paths
zz-<host> packages nest base-package dirs internally (zz-blankpad/niri/.config/...); stripping only the package prefix yielded targets like $HOME/niri/.config/... . Strip the nested package segment for zz-* packages so overrides land on the same home-relative target as the base copy they override.
This commit is contained in:
1 parent
5efb218061
commit
cc2c652cc2
1 file changed
+4
-1
+4
-1
@@ -98,7 +98,10 @@ for pkg in "${PKGS[@]}"; do
|
|||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
while IFS= read -r -d '' f; do
|
while IFS= read -r -d '' f; do
|
||||||
deploy_file "$f" "${f#"$pkg"/}"
|
rel="${f#"$pkg"/}"
|
||||||
|
# override packages nest base-package dirs internally: strip that segment for targets
|
||||||
|
if [ "${pkgname#zz-}" != "$pkgname" ]; then case "$rel" in */*) [ -d "$PKGS_DIR/${rel%%/*}" ] && rel="${rel#*/}";; esac; fi
|
||||||
|
deploy_file "$f" "$rel"
|
||||||
done < <(find "$pkg" -type f ! -name 'dump.txt' -print0)
|
done < <(find "$pkg" -type f ! -name 'dump.txt' -print0)
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user