Subject: [PATCH] revert/cherry-pick: allow the last parameter to be -h

From: Jonas Fonseca <[email-masked]>
Date: Tue, 22 May 2007 23:29:45 +0200

... to ask for the usage string.

Signed-off-by: Jonas Fonseca <[email-masked]>
---
 builtin-revert.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/builtin-revert.c b/builtin-revert.c
index ea2f15b..7984aeb 100644
--- a/builtin-revert.c
+++ b/builtin-revert.c
@@ -61,6 +61,8 @@ static void parse_options(int argc, const char **argv)
 	}
 
 	arg = argv[argc - 1];
+	if (!strcmp(arg, "-h"))
+		usage(usage_str);
 	if (get_sha1(arg, sha1))
 		die ("Cannot find '%s'", arg);
 	commit = (struct commit *)parse_object(sha1);
-- 
1.5.2.rc3.800.ga489e-dirty

-- 
Jonas Fonseca