Skip to content

Instantly share code, notes, and snippets.

@lopezjurip
Created May 24, 2015
Embed
What would you like to do?
[Bash] For-each on directories
START_HERE="/Users/user/repositories";
cd $START_HERE;
for d in $(find . -maxdepth 1 -mindepth 1 -type d); do
echo -e "$d";
cd $d;
# Do a barrel roll
git pull;
cd $START_HERE;
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment