Git development
 help / color / mirror / Atom feed
* [PATCH] revert/cherry-pick: allow the last parameter to be -h
@ 2007-05-22 21:29 Jonas Fonseca
  2007-05-22 22:11 ` Alex Riesen
  0 siblings, 1 reply; 7+ messages in thread
From: Jonas Fonseca @ 2007-05-22 21:29 UTC (permalink / raw)
  To: git; +Cc: Junio C Hamano

... to ask for the usage string.

Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
---
 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

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2007-05-23  7:04 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-22 21:29 [PATCH] revert/cherry-pick: allow the last parameter to be -h Jonas Fonseca
2007-05-22 22:11 ` Alex Riesen
2007-05-22 22:23   ` Junio C Hamano
2007-05-23  5:31     ` Jonas Fonseca
2007-05-23  5:52       ` Junio C Hamano
2007-05-23  6:57         ` Jonas Fonseca
2007-05-23  7:04           ` Junio C Hamano

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox