Skip to content

Instantly share code, notes, and snippets.

@veggiemonk
Last active July 9, 2019 19:54
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 veggiemonk/3a9c2ef6bbe36308982c72b9230bc451 to your computer and use it in GitHub Desktop.
Save veggiemonk/3a9c2ef6bbe36308982c72b9230bc451 to your computer and use it in GitHub Desktop.
organize your git repo like go
#!/bin/bash
for r in *;
do {
echo ">>> $r" && \
cd $r && \
(git pull || echo 0) && \
cd ..
};
done;
#!/bin/bash
for r in *;
do {
cd $r || break
git remote -v 2> /dev/null | grep fetch | sed 's/https\:\/\/github\.com\///g' | sed 's/git\@github\.com\://g' | sed 's/origin//g' || true
cd ..
};
done;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment