Skip to content

Commit

Permalink
git-fetch: always show status of non-tracking-ref fetches
Browse files Browse the repository at this point in the history
Previously, a fetch like:

  git fetch git://some/url

would show no ref status output (just the object downloading
status, if there was any), leading to some confusion.

With this patch, we now show the usual ref table, with
remote refs going into FETCH_HEAD. Previously this output
was shown only if "-v"erbose was specified.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Jeff King authored and Junio C Hamano committed Apr 10, 2008
1 parent 7134973 commit e5c4982
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions builtin-fetch.c
Original file line number Diff line number Diff line change
Expand Up @@ -360,12 +360,10 @@ static int store_updated_refs(const char *url, struct ref *ref_map)

if (ref)
update_local_ref(ref, what, verbose, note);
else if (verbose)
else
sprintf(note, "* %-*s %-*s -> FETCH_HEAD",
SUMMARY_WIDTH, *kind ? kind : "branch",
REFCOL_WIDTH, *what ? what : "HEAD");
else
*note = '\0';
if (*note) {
if (!shown_url) {
fprintf(stderr, "From %.*s\n",
Expand Down

0 comments on commit e5c4982

Please sign in to comment.