From 2c933f0815a27d1f67b60fd64ae88d5a6b0d542c Mon Sep 17 00:00:00 2001 From: Simon Ruderich Date: Fri, 20 Feb 2009 19:02:54 -0600 Subject: [PATCH] Find git directories in setup.sh automatically. --- setup.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/setup.sh b/setup.sh index 98c9100..2f8472a 100755 --- a/setup.sh +++ b/setup.sh @@ -8,7 +8,10 @@ projects="browser lftp mail music os shell vcs vim" # Run setup.sh in each project. -for project in $projects; do +for project in `find . -name .git -type d`; do + # Skip this directory to prevent an infinite loop. + [ "$project" = "./.git" ] && continue + [ -d "$project" ] && (echo "running setup.sh in '$project'"; - cd "$project"; ./setup.sh > /dev/null) + cd "$project/.."; ./setup.sh > /dev/null) done -- 2.45.2