]> git.ipfire.org Git - thirdparty/git.git/blobdiff - contrib/examples/git-gc.sh
Supplant the "while case ... break ;; esac" idiom
[thirdparty/git.git] / contrib / examples / git-gc.sh
index 436d7caff5c26f7c0ff8c0a410bdabccdec0a900..1597e9f33f5e001995085639a448f1214010b561 100755 (executable)
@@ -9,7 +9,7 @@ SUBDIRECTORY_OK=Yes
 . git-sh-setup
 
 no_prune=:
-while case $# in 0) break ;; esac
+while test $# != 0
 do
        case "$1" in
        --prune)
@@ -30,8 +30,8 @@ notbare|"")
 esac
 
 test "true" != "$pack_refs" ||
-git-pack-refs --prune &&
-git-reflog expire --all &&
+git pack-refs --prune &&
+git reflog expire --all &&
 git-repack -a -d -l &&
-$no_prune git-prune &&
-git-rerere gc || exit
+$no_prune git prune &&
+git rerere gc || exit