MCPcopy Create free account
hub / github.com/git/git / print_compact

Function print_compact

builtin/fetch.c:788–808  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

786}
787
788static void print_compact(struct display_state *display_state,
789 const char *remote, const char *local)
790{
791 struct strbuf r = STRBUF_INIT;
792 struct strbuf l = STRBUF_INIT;
793
794 if (!strcmp(remote, local)) {
795 strbuf_addf(&display_state->buf, "%-*s -> *", display_state->refcol_width, remote);
796 return;
797 }
798
799 strbuf_addstr(&r, remote);
800 strbuf_addstr(&l, local);
801
802 if (!find_and_replace(&r, local, "*"))
803 find_and_replace(&l, remote, "*");
804 print_remote_to_local(display_state, r.buf, l.buf);
805
806 strbuf_release(&r);
807 strbuf_release(&l);
808}
809
810static void display_ref_update(struct display_state *display_state, char code,
811 const char *summary, const char *error,

Callers 1

display_ref_updateFunction · 0.85

Calls 5

strbuf_addfFunction · 0.85
strbuf_addstrFunction · 0.85
find_and_replaceFunction · 0.85
print_remote_to_localFunction · 0.85
strbuf_releaseFunction · 0.85

Tested by

no test coverage detected