diff --git a/scripts/shell/git-sync-all.sh b/scripts/shell/git-sync-all.sh index 52a4330..5e85fb2 100755 --- a/scripts/shell/git-sync-all.sh +++ b/scripts/shell/git-sync-all.sh @@ -24,34 +24,3 @@ for i in "${!SYNC_DIRS[@]}"; do git status --porcelain ) done - -# Pull NixOS, home-manager and Emacs configs if simple fast-forward -PULL_DIRS=( - "${XDG_CONFIG_HOME:-$HOME/.config}/nixos" - "${XDG_CONFIG_HOME:-$HOME/.config}/home-manager" - "${XDG_CONFIG_HOME:-$HOME/.config}/emacs" -) -PULL_URLS=( - "https://git.xenia.me.uk/pixelifytica/nixos.git" - "https://git.xenia.me.uk/pixelifytica/home-manager.git" - "https://git.xenia.me.uk/pixelifytica/emacs.git" -) -for i in "${!PULL_DIRS[@]}"; do - DIRECTORY="${PULL_DIRS[$i]}" - URL="${PULL_URLS[$i]}" - echo "--- pull: $DIRECTORY ---" - if [ ! -d "$DIRECTORY" ]; then - git clone "$URL" "$DIRECTORY" - fi - ( - cd "$DIRECTORY" || exit - if [ "$(git branch --show-current)" = "main" ]; then - git remote set-url origin "$URL" - git pull --ff --ff-only - git push - else - echo "Not syncing repo $DIRECTORY on branch $(git branch --show-current)" - fi - git status --porcelain - ) -done