From 17984344ee4aaf2813c289d3e8654f3d8046c970 Mon Sep 17 00:00:00 2001 From: clsty Date: Sun, 5 Oct 2025 10:26:43 +0800 Subject: [PATCH] Use `arg_excludes` for rsync --- scriptdata/step/3.install-files.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/scriptdata/step/3.install-files.sh b/scriptdata/step/3.install-files.sh index ac0639567..84682d9b9 100644 --- a/scriptdata/step/3.install-files.sh +++ b/scriptdata/step/3.install-files.sh @@ -65,10 +65,15 @@ case $SKIP_FISH in esac # For Hyprland +declare -a arg_excludes=() +arg_excludes+=(--exclude '/custom') +arg_excludes+=(--exclude '/hyprlock.conf') +arg_excludes+=(--exclude '/hypridle.conf') +arg_excludes+=(--exclude '/hyprland.conf') case $SKIP_HYPRLAND in true) sleep 0;; *) - v rsync -av --delete --exclude '/custom' --exclude '/hyprlock.conf' --exclude '/hypridle.conf' --exclude '/hyprland.conf' .config/hypr/ "$XDG_CONFIG_HOME"/hypr/ + v rsync -av --delete "${arg_excludes[@]}" .config/hypr/ "$XDG_CONFIG_HOME"/hypr/ t="$XDG_CONFIG_HOME/hypr/hyprland.conf" if [ -f $t ];then echo -e "${STY_BLUE}[$0]: \"$t\" already exists.${STY_RESET}" @@ -109,6 +114,7 @@ case $SKIP_HYPRLAND in fi ;; esac +declare -a arg_excludes=() # some foldes (eg. .local/bin) should be processed separately to avoid `--delete' for rsync,