]> git.ipfire.org Git - thirdparty/git.git/commitdiff
Merge branch 'ps/fetch-ref-update-reporting'
authorJunio C Hamano <gitster@pobox.com>
Thu, 6 Apr 2023 20:38:28 +0000 (13:38 -0700)
committerJunio C Hamano <gitster@pobox.com>
Thu, 6 Apr 2023 20:38:28 +0000 (13:38 -0700)
Clean-up of the code path that reports what "git fetch" did to each
ref.

* ps/fetch-ref-update-reporting:
  fetch: centralize printing of reference updates
  fetch: centralize logic to print remote URL
  fetch: centralize handling of per-reference format
  fetch: pass the full local reference name to `format_display`
  fetch: move output format into `display_state`
  fetch: move reference width calculation into `display_state`

1  2 
builtin/fetch.c

diff --cc builtin/fetch.c
index 7221e57f3529f22104b55a7200d5df04c2c4e63d,c202c18fb48f979d991cf937ec0c9084c5405a3c..c310d89878afd8ac39a5c241080819914d24cc8c
@@@ -1128,15 -1175,10 +1176,11 @@@ static int store_updated_refs(struct di
        if (!connectivity_checked) {
                struct check_connected_options opt = CHECK_CONNECTED_INIT;
  
 +              opt.exclude_hidden_refs_section = "fetch";
                rm = ref_map;
                if (check_connected(iterate_ref_map, &rm, &opt)) {
-                       rc = error(_("%s did not send all necessary objects\n"), url);
+                       rc = error(_("%s did not send all necessary objects\n"),
+                                  display_state->url);
                        goto abort;
                }
        }