threads / patch / 2956

patchgit potty: grok 'help' to mean '--help'.

Subject: [PATCH] git potty: grok 'help' to mean '--help'.

## tl;dr

One message between Jan 3, 2006 and Jan 3, 2006. Diffs are folded; open one to read it.

replies: 0people: 1as markdown or json

Andreas Ericsson· Jan 3, 2006, 09:53 UTC · lore
Most other scm's understand it, most users expect it and it's an easy fix.
Signed-off-by: Andreas Ericsson <ae@op5.se>
---
 git.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
bd2573445899c427adac66f2b0fe4643461ab280
Show changes to git.c +5 −0
diff --git a/git.c b/git.c
index e795ddb..5e7da74 100644
--- a/git.c
+++ b/git.c
@@ -244,6 +244,11 @@ int main(int argc, char **argv, char **e
 	for (i = 1; i < argc; i++) {
 		char *arg = argv[i];
 
+		if (!strcmp(arg, "help")) {
+			show_help = 1;
+			continue;
+		}
+
 		if (strncmp(arg, "--", 2))
 			break;
 
-- 
1.0.6-g58e3

← back to recent threads