This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# store the current dir | |
CUR_DIR=$(pwd) | |
# Let the person running the script know what's going on. | |
echo "Pulling in latest changes for all repositories..." | |
# Find all git repositories and update origin for all of them | |
for i in $(find . -name ".git" | cut -c 3-); do |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# pull all Git repos inside a folder | |
dir -r -i .git -fo | % { pushd $_.fullname; cd ..; write-host -fore yellow (get-location).Path; git pull --rebase; git status; git gc; popd }; | |
# update all SVN repos | |
# dir -r -i .svn -fo | % { pushd $_.fullname; cd ..; write-host -fore yellow (get-location).Path; svn update; svn status; popd } | |
Read-Host "Press ENTER to exit" |