Skip to content

Instantly share code, notes, and snippets.

@gertd
Last active August 9, 2019 01:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gertd/77d3eb958da2c75e2cfb5ae6fbbf859d to your computer and use it in GitHub Desktop.
Save gertd/77d3eb958da2c75e2cfb5ae6fbbf859d to your computer and use it in GitHub Desktop.
git-pull - pull all repos in current directory helper script
#!/usr/bin/env bash
basedir=$PWD
for dir in $(find "$basedir" -mindepth 1 -maxdepth 4 -type d); do
[ -d "$dir/.git" ] && echo $dir && cd $dir && git pull && cd ..
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment