mirror of
https://github.com/git/git.git
synced 2025-12-12 20:36:24 +01:00
archive: "--list" does not take further options
"git archive --list blah" should notice an extra command line parameter that goes unused. Make it so. Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
@@ -685,6 +685,8 @@ static int parse_archive_args(int argc, const char **argv,
|
||||
base = "";
|
||||
|
||||
if (list) {
|
||||
if (argc)
|
||||
die(_("extra command line parameter '%s'"), *argv);
|
||||
for (i = 0; i < nr_archivers; i++)
|
||||
if (!is_remote || archivers[i]->flags & ARCHIVER_REMOTE)
|
||||
printf("%s\n", archivers[i]->name);
|
||||
|
||||
Reference in New Issue
Block a user