MCPcopy Index your code
hub / github.com/git/git / graph_show_commit_msg

Function graph_show_commit_msg

graph.c:1649–1685  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1647}
1648
1649void graph_show_commit_msg(struct git_graph *graph,
1650 FILE *file,
1651 struct strbuf const *sb)
1652{
1653 int newline_terminated;
1654
1655 /*
1656 * Show the commit message
1657 */
1658 graph_show_strbuf(graph, file, sb);
1659
1660 if (!graph)
1661 return;
1662
1663 newline_terminated = (sb->len && sb->buf[sb->len - 1] == '\n');
1664
1665 /*
1666 * If there is more output needed for this commit, show it now
1667 */
1668 if (!graph_is_commit_finished(graph)) {
1669 /*
1670 * If sb doesn't have a terminating newline, print one now,
1671 * so we can start the remainder of the graph output on a
1672 * new line.
1673 */
1674 if (!newline_terminated)
1675 putc('\n', file);
1676
1677 graph_show_remainder(graph);
1678
1679 /*
1680 * If sb ends with a newline, our output should too.
1681 */
1682 if (newline_terminated)
1683 putc('\n', file);
1684 }
1685}

Callers 2

show_logFunction · 0.85
show_commitFunction · 0.85

Calls 3

graph_show_strbufFunction · 0.85
graph_is_commit_finishedFunction · 0.85
graph_show_remainderFunction · 0.85

Tested by

no test coverage detected