merge(3p/cgit): subtree merge at adcc4f82
Change-Id: I16941629a17a2f39b9324cb85dc0cec6b104dfe4
This commit is contained in:
parent
f4609b896f
commit
1e81ce6622
26 changed files with 299 additions and 135 deletions
12
third_party/cgit/ui-commit.c
vendored
12
third_party/cgit/ui-commit.c
vendored
|
|
@ -71,15 +71,15 @@ void cgit_print_commit(char *hex, const char *prefix)
|
|||
html_txt(show_date(info->committer_date, info->committer_tz,
|
||||
cgit_date_mode(DATE_DOTTIME)));
|
||||
html("</td></tr>\n");
|
||||
html("<tr><th>commit</th><td colspan='2' class='sha1'>");
|
||||
html("<tr><th>commit</th><td colspan='2' class='oid'>");
|
||||
tmp = oid_to_hex(&commit->object.oid);
|
||||
cgit_commit_link(tmp, NULL, NULL, ctx.qry.head, tmp, prefix);
|
||||
html(" (");
|
||||
cgit_patch_link("patch", NULL, NULL, NULL, tmp, prefix);
|
||||
html(")</td></tr>\n");
|
||||
html("<tr><th>tree</th><td colspan='2' class='sha1'>");
|
||||
html("<tr><th>tree</th><td colspan='2' class='oid'>");
|
||||
tmp = xstrdup(hex);
|
||||
cgit_tree_link(oid_to_hex(&commit->maybe_tree->object.oid), NULL, NULL,
|
||||
cgit_tree_link(oid_to_hex(get_commit_tree_oid(commit)), NULL, NULL,
|
||||
ctx.qry.head, tmp, NULL);
|
||||
if (prefix) {
|
||||
html(" /");
|
||||
|
|
@ -96,7 +96,7 @@ void cgit_print_commit(char *hex, const char *prefix)
|
|||
continue;
|
||||
}
|
||||
html("<tr><th>parent</th>"
|
||||
"<td colspan='2' class='sha1'>");
|
||||
"<td colspan='2' class='oid'>");
|
||||
tmp = tmp2 = oid_to_hex(&p->item->object.oid);
|
||||
if (ctx.repo->enable_subject_links) {
|
||||
parent_info = cgit_parse_commit(parent);
|
||||
|
|
@ -110,7 +110,7 @@ void cgit_print_commit(char *hex, const char *prefix)
|
|||
parents++;
|
||||
}
|
||||
if (ctx.repo->snapshots) {
|
||||
html("<tr><th>download</th><td colspan='2' class='sha1'>");
|
||||
html("<tr><th>download</th><td colspan='2' class='oid'>");
|
||||
cgit_print_snapshot_links(ctx.repo, hex, "<br/>");
|
||||
html("</td></tr>");
|
||||
}
|
||||
|
|
@ -140,7 +140,7 @@ void cgit_print_commit(char *hex, const char *prefix)
|
|||
tmp = oid_to_hex(&commit->parents->item->object.oid);
|
||||
else
|
||||
tmp = NULL;
|
||||
cgit_print_diff(ctx.qry.sha1, tmp, prefix, 0, 0);
|
||||
cgit_print_diff(ctx.qry.oid, tmp, prefix, 0, 0);
|
||||
}
|
||||
strbuf_release(¬es);
|
||||
cgit_free_commitinfo(info);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue