Code

git: grok 'help' to mean '--help'.
authorAndreas Ericsson <exon@op5.se>
Tue, 3 Jan 2006 09:53:54 +0000 (10:53 +0100)
committerJunio C Hamano <junkio@cox.net>
Fri, 6 Jan 2006 04:28:52 +0000 (20:28 -0800)
Most other scm's understand it, most users expect it and it's an easy fix.

Signed-off-by: Andreas Ericsson <ae@op5.se>
Signed-off-by: Junio C Hamano <junkio@cox.net>
git.c

diff --git a/git.c b/git.c
index e795ddb8106138920ad02793c4f4b787e05fb4f4..5e7da74b6800a4256f9bcb0d0add7560213271e1 100644 (file)
--- a/git.c
+++ b/git.c
@@ -244,6 +244,11 @@ int main(int argc, char **argv, char **envp)
        for (i = 1; i < argc; i++) {
                char *arg = argv[i];
 
+               if (!strcmp(arg, "help")) {
+                       show_help = 1;
+                       continue;
+               }
+
                if (strncmp(arg, "--", 2))
                        break;