X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=builtin-push.c;h=d23974e708cb744f75efbb9f1acbf37606e92b05;hb=76c3eb51ede4619116ef980aa34d087c97c25cbc;hp=5f7eccf14b272fc108bcd49aece911ebde460b4f;hpb=9004dcbe8278b6d66f41e6e401f6d564a64fd1e1;p=git.git diff --git a/builtin-push.c b/builtin-push.c index 5f7eccf14..d23974e70 100644 --- a/builtin-push.c +++ b/builtin-push.c @@ -10,7 +10,7 @@ static const char push_usage[] = "git-push [--all] [--tags] [-f | --force] [...]"; -static int all, tags, force, thin = 1; +static int all, tags, force, thin = 1, verbose; static const char *execute; #define BUF_SIZE (2084) @@ -248,6 +248,8 @@ static int do_push(const char *repo) while (dest_refspec_nr--) argv[dest_argc++] = *dest_refspec++; argv[dest_argc] = NULL; + if (verbose) + fprintf(stderr, "Pushing to %s\n", dest); err = run_command_v(argc, argv); if (!err) continue; @@ -281,6 +283,14 @@ int cmd_push(int argc, const char **argv, const char *prefix) i++; break; } + if (!strcmp(arg, "-v")) { + verbose=1; + continue; + } + if (!strncmp(arg, "--repo=", 7)) { + repo = arg+7; + continue; + } if (!strcmp(arg, "--all")) { all = 1; continue;