djcev.com

//

Git Repos / blogofile_gitview / _templates / gitview / git_commit.mako

Last update to this file was on 2022-01-23 at 14:14.

Show git_commit.mako

<%inherit file="site.mako"/>\
<%
repolink = bf.util.path_join(bf.config.gitview.path, repo['name'])
%>\
<%def name="git_header(name, l, extra)">\
<%include file="git_header.mako" args="name=name, lastcommit=l, extra=extra"/>\
</%def>\
<article>
${self.git_header(repo['name'], repo['last_commit'],
"commit " + commitinfo['id'][:7])}
<section class="commitinfo"><p>
Commit: <a href="${commitinfo['id']}.html">${commitinfo['id']}</a><br/>
% for p in commitinfo['parentids']:
% if prev_id and len(commitinfo['parentids']) == 1:
Parent: <a href="${p}.html">${p}</a><br/>
% else:
Parent: ${p}<br/>
% endif
% endfor
Author: ${commitinfo['author']} &lt;${commitinfo['author_email']}&gt;,
${commitinfo['author_time'].strftime("%Y-%m-%d %H:%M")}<br/>
Committer: ${commitinfo['committer']} &lt;${commitinfo['committer_email']}&gt;,
${commitinfo['committer_time'].strftime("%Y-%m-%d %H:%M")}<br/>
</p>
<h3>Commit Message</h3>
<pre>${commitinfo['msg']}</pre>
</section>
% if len(commitinfo['deltas']) > 0 and len(commitinfo['patches']) > 0:
<h3>Change List & Diffs</h3>
<section class="changelist">
% for i, delta in enumerate(commitinfo['deltas']):
% if i == 0:
<table><tr>
<th class="cstatus">?</th><th class="filename">File</th>
<th class="cadd">Add</th><th class="cdel">Del</th></tr>
% endif
<tr><td class="cstatus">${delta['status']}</td>
<td class="filename">
<a href="${commitinfo['id']}.html#${i}">${delta['oldpath']}</a></td>
% if delta['add']:
<td class="cadd">+${delta['add']}</td>
% else:
<td class="cadd"></td>
% endif
% if delta['del']:
<td class="cdel">-${delta['del']}</td>
% else:
<td class="cdel"></td>
% endif
</tr>
% if i == (len(commitinfo['deltas']) - 1):
</table>
% endif
% endfor
</section>
% for i, patch in enumerate(commitinfo['patches']):
<h4 id="${i}">${commitinfo['deltas'][i]['oldpath']}</h4>
<section class="diff">
${patch}\
</section>
<p><a href="#top">Return to top of this page</a> or
<a href="/${repolink}">return to the overview of this repository</a></p>
% endfor
% endif
</article>
% if prev_id or next_id:
<hr class="bright"/>
<nav><p class="clearfix">
% if next_id:
<a href="${next_id}.html" title="Next Commit">&lt;&lt; Next Commit</a>
% endif
% if prev_id:
<a class="rg" href="${prev_id}.html" title="Previous Commit">
Previous Commit &gt;&gt;</a>
% endif
</p></nav>\
% endif

Return to the top of this page or return to the overview of this repo.

Log git_commit.mako

Date Commit Message Author + -
2022-01-23 More file extension handling, small template fix cev +8 -8
2021-08-01 Add missing stats to templates, change tag check cev +2 -2
2021-07-31 Implement branches & tags, various other changes cev +38 -21
2021-07-25 Initial commit cev +60  

Return to the top of this page or return to the overview of this repo.