[PATCH 18/25] git-repack: Print usage message on unrecognized option.
Signed-off-by: Fredrik Kuivinen <freku045@student.liu.se>
---
git-repack.sh | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
3616296531a068dcbe5a39f8864ddde3b3067969
diff --git a/git-repack.sh b/git-repack.sh
index 430ddc5..9752032 100755
--- a/git-repack.sh
+++ b/git-repack.sh
@@ -4,7 +4,11 @@
#
. git-sh-setup
-
+
+usage () {
+ die "usage: $0 [-a] [-d] [-l] [-n]"
+}
+
no_update_info= all_into_one= remove_redundant= local=
while case "$#" in 0) break ;; esac
do
@@ -13,6 +17,7 @@ do
-a) all_into_one=t ;;
-d) remove_redundant=t ;;
-l) local=t ;;
+ -*) usage ;;
*) break ;;
esac
shift
--
0.99.9.GIT