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

Function show_decorations

log-tree.c:423–438  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

421}
422
423void show_decorations(struct rev_info *opt, struct commit *commit)
424{
425 struct strbuf sb = STRBUF_INIT;
426
427 if (opt->sources) {
428 char **slot = revision_sources_peek(opt->sources, commit);
429
430 if (slot && *slot)
431 fprintf(opt->diffopt.file, "\t%s", *slot);
432 }
433 if (!opt->show_decorations)
434 return;
435 format_decorations(&sb, commit, opt->diffopt.use_color, NULL);
436 fputs(sb.buf, opt->diffopt.file);
437 strbuf_release(&sb);
438}
439
440void fmt_output_subject(struct strbuf *filename,
441 const char *subject,

Callers 2

show_logFunction · 0.85
show_commitFunction · 0.85

Calls 2

format_decorationsFunction · 0.85
strbuf_releaseFunction · 0.85

Tested by

no test coverage detected