]> git.phdru.name Git - git-scripts.git/blobdiff - do-all
Do something on all located git repositories
[git-scripts.git] / do-all
diff --git a/do-all b/do-all
new file mode 100755 (executable)
index 0000000..2a8e19b
--- /dev/null
+++ b/do-all
@@ -0,0 +1,11 @@
+#! /usr/bin/env bash
+
+prog_dir="`dirname \"$0\"`" &&
+
+while true; do
+   read d || exit 0
+   if ! test -d "$d"; then continue; fi
+   test -d "$d"/.git && g="$d"/.git || g="$d"
+   b="`basename \"$d\" .git`"
+   eval "$@"
+done < "$prog_dir"/locate-all.list