Skip to content

Instantly share code, notes, and snippets.

@davidmfoley
Created September 6, 2012 14:59
Show Gist options
  • Save davidmfoley/3657086 to your computer and use it in GitHub Desktop.
Save davidmfoley/3657086 to your computer and use it in GitHub Desktop.
update git repos in all subdirectories
DIR=$( cd "$( dirname "$0" )" && pwd )
pushd $DIR
for d in `ls -d */`
do
echo "$d"
pushd "$d" > /dev/null
git remote update --prune
popd > /dev/null
done
popd > /dev/null
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment