Code

ls-remote: add -t and -h options.
authorMiklos Vajna <vmiklos@frugalware.org>
Tue, 15 Jan 2008 20:34:54 +0000 (21:34 +0100)
committerJunio C Hamano <gitster@pobox.com>
Wed, 16 Jan 2008 01:04:21 +0000 (17:04 -0800)
These options are listed in the manpage (aliases for --tags/--heads) but they
were not handled.

Signed-off-by: Miklos Vajna <vmiklos@frugalware.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin-ls-remote.c

index c2caeeabe2f9d2bce190656a58094b5ebeee4e30..6dd31d1dd6c14677f91e8a0a941fb0f873b4c1fc 100644 (file)
@@ -54,11 +54,11 @@ int cmd_ls_remote(int argc, const char **argv, const char *prefix)
                                uploadpack = arg + 7;
                                continue;
                        }
-                       if (!strcmp("--tags", arg)) {
+                       if (!strcmp("--tags", arg) || !strcmp("-t", arg)) {
                                flags |= REF_TAGS;
                                continue;
                        }
-                       if (!strcmp("--heads", arg)) {
+                       if (!strcmp("--heads", arg) || !strcmp("-h", arg)) {
                                flags |= REF_HEADS;
                                continue;
                        }