can specifiy target git dir
[infrastructure.git] / scripts / git-check.sh
index 290a243..8b80765 100755 (executable)
@@ -31,7 +31,7 @@ function fill_descriptions () {
        b=$(basename $arg .git)
        git=${b}.git
        echo -n "$git "
-       grep Unnamed $git/description && { echo -n $i "Setting.. "; echo $b > $git/description ; }
+       grep -q Unnamed $git/description && { echo -n $i "Setting.. "; echo $b > $git/description ; }
     done
     echo ""
 }
@@ -56,5 +56,7 @@ EOF
 }
 
 missing_gitweb
-fill_descriptions $(ls *.git)
-upload_archives $(ls *.git)
+args="$@"
+[[ -z "$args" ]] && args=$(ls -d *.git)
+fill_descriptions $args
+upload_archives $args