1
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:py="http://purl.org/kid/ns#"
3
py:extends="'master.kid'">
5
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" py:replace="''"/>
6
<title> ${branch.friendly_name} : revision ${change.revno} </title>
8
<span py:strip="True" py:def="file_link(filename, file_id)">
9
<a href="${branch.url([ '/annotate', revid ],
10
**util.get_context(file_id=file_id))}" title="Annotate ${filename}">${filename}</a>
12
<span py:strip="True" py:def="file_link_rev(filename, file_id, revid)">
13
<a href="${branch.url([ '/annotate', revid ],
14
**util.get_context(file_id=file_id))}" title="Annotate ${filename} at revision ${history.get_revno(revid)}">${filename}</a>
17
<span py:replace="use_collapse_buttons()"></span>
19
<script type="text/javascript"> <!--
20
function show_sbs(path) {
21
collapseDisplay('style', 'sbs', 'table');
22
collapseDisplay('style', 'unified', 'none');
23
document.cookie='diff=sbs; path=' + path;
25
function show_unified(path) {
26
collapseDisplay('style', 'unified', 'table');
27
collapseDisplay('style', 'sbs', 'none');
28
document.cookie='diff=unified; path=' + path;
31
sortCollapseElements();
32
if (document.cookie.indexOf('diff=unified') >= 0) {
35
if (document.cookie.indexOf('stop=1') >= 0) {
38
if (document.cookie.indexOf('diff=unified') >= 0) {
39
window.location.hash = window.location.hash;
40
document.cookie='stop=1; max-age=5; path=' + window.location.pathname;
46
<body onload="javascript:load('${branch.url('/')}')">
50
<h1> <span class="branch-name">${branch.friendly_name}</span> : revision ${change.revno}
51
<span py:if="compare_revid is not None"> (compared to revision ${history.get_revno(compare_revid)}) </span>
54
<div> <b>→</b> <a href="${branch.context_url([ '/files', revid ])}">
55
browse files at revision ${change.revno} </a> </div>
56
<div> <b>→</b> <a href="${branch.context_url('/changes', start_revid=revid)}">
57
view history from revision ${change.revno} </a> </div>
58
<span py:if="compare_revid is not None" py:strip="True">
59
<div> <b>→</b> <a href="${branch.url([ '/bundle', revid, compare_revid, 'bundle.txt' ])}">
60
download bundle from ${history.get_revno(compare_revid)} to ${change.revno} </a> </div>
62
<span py:if="(remember is not None) and (compare_revid is None) and (revid != remember)" py:strip="True">
63
<div> <b>→</b> <a href="${branch.context_url([ '/revision', revid ], compare_revid=remember)}">
64
compare with revision ${history.get_revno(remember)} </a></div>
66
<span py:if="remember != revid" py:strip="True">
67
<div> <b>→</b> <a href="${branch.context_url([ '/revision', revid ], remember=revid, compare_revid=None)}">
68
compare with another revision </a></div>
70
<span py:if="compare_revid is not None" py:strip="True">
71
<div> <b>→</b> <a href="${branch.context_url([ '/revision', compare_revid ], remember=revid, compare_revid=revid)}">
72
reverse the comparison (${change.revno} to ${history.get_revno(compare_revid)})</a></div>
73
<div> <b>→</b> <a href="${branch.context_url([ '/revision', revid ], remember=None, compare_revid=None)}">
74
stop comparing with revision ${history.get_revno(compare_revid)} </a></div>
79
<div class="revision-info">
82
<th class="author">committed by:</th>
83
<td class="author"> ${util.hide_email(change.author)} </td>
86
<th class="date">date:</th>
87
<td class="date"> ${util.format_date(change.date)} </td>
90
<tr py:if="len(change.merge_points) > 0">
91
<th class="children"> merged in: </th>
93
<span py:for="child in change.merge_points">
94
${revision_link(child.revid, '(' + child.revno + util.if_present(' %s', child.branch_nick) + ')', clear=1, start_revid=child.revid)} <br />
98
<tr py:if="len(change.parents) > 1">
99
<th class="parents"> merged from: </th>
101
<span py:for="parent in change.parents"><span py:if="parent.revid != change.parents[0].revid">
102
${revision_link(parent.revid, '(' + parent.revno + util.if_present(' %s', parent.branch_nick) + ')', clear=1, start_revid=parent.revid)} <br />
108
<th class="description">description:</th>
109
<td class="description"><span py:for="line in change.comment_clean">${XML(line)} <br /></span> </td>
112
<tr class="divider"> <th></th> <td></td> </tr>
114
<tr py:if="change.changes.added">
115
<th class="files"> files added: </th>
116
<td class="files"> <span py:for="filename, file_id in change.changes.added" class="filename">${file_link(filename, file_id)} <br /></span> </td>
118
<tr py:if="change.changes.removed">
119
<th class="files"> files removed: </th>
120
<td class="files"> <span py:for="filename, file_id in change.changes.removed" class="filename">
121
${file_link_rev(filename, file_id, change.parents[0].revid)} <br /></span>
124
<tr py:if="change.changes.renamed">
125
<th class="files"> files renamed: </th>
126
<td class="files"> <span py:for="old_filename, new_filename, file_id in change.changes.renamed" class="filename">
127
${file_link(old_filename, file_id)} => ${file_link(new_filename, file_id)}<br />
130
<tr py:if="change.changes.modified">
131
<th class="files"> files modified: </th>
133
<span py:for="item in change.changes.modified" class="collapse-style-sbs-content">
134
<a href="#${item.filename}-s" class="filename" title="Jump to ${item.filename} below">${item.filename}</a><br />
136
<span py:for="item in change.changes.modified" class="collapse-style-unified-content">
137
<a href="#${item.filename}-u" class="filename" title="Jump to ${item.filename} below">${item.filename}</a><br />
144
<table class="diff-option-buttons">
146
<td> ${collapse_all_button('file', 'table-row')} </td>
149
<a href="javascript:show_sbs('${branch.url('/')}')" class="hide-all collapse-style-sbs-show" title="collapse">
150
<img src="${tg.url('/static/images/nav-small-out.gif')}" width="22" height="10" class="collapse-triangle" />show side by side</a>
151
<a href="javascript:show_unified('${branch.url('/')}')" class="hide-all collapse-style-unified-show" title="expand">
152
<img src="${tg.url('/static/images/nav-small-in.gif')}" width="22" height="10" class="collapse-triangle" />show unified diff</a>
155
<td class="diff-key-block diff-insert"></td>
156
<td class="label"> added </td>
157
<td class="diff-key-block diff-delete"></td>
158
<td class="label"> removed</td>
162
<!-- ! i'm not a big fan of embedding python code here, but the alternatives all seem to be worse -->
163
<?python uniqs={}; ?>
165
<div class="diff" py:if="change.changes.modified">
166
<!-- ! side-by-side diff -->
167
<table class="diff-block collapse-style-sbs-content">
168
<span py:strip="True" py:for="item in change.changes.modified">
169
<tr><th class="filename" colspan="4">
170
${collapse_button('file', util.uniq(uniqs, item.file_id), 'table-row')}
171
<a href="${branch.url([ '/annotate', change.revid ], **util.get_context(file_id=item.file_id))}"
172
name="${item.filename}-s" title="Annotate ${item.filename}">${item.filename}</a>
175
<span py:strip="True" py:for="chunk in item.sbs_chunks">
176
<tr class="diff-chunk collapse-file-${util.uniq(uniqs, item.file_id)}-content">
177
<th class="lineno">old</th> <th></th> <th class="lineno">new</th> <th></th>
179
<tr py:for="line in chunk.diff" class="diff-chunk collapse-file-${util.uniq(uniqs, item.file_id)}-content">
180
<span py:if="line.old_lineno" py:strip="True">
181
<td class="lineno">${line.old_lineno}</td>
182
<td class="diff-${line.old_type}">${line.old_line}</td>
184
<span py:if="not line.old_lineno" py:strip="True">
185
<td class="lineno-skip">${line.old_lineno}</td>
186
<td class="diff-${line.old_type}-skip">${line.old_line}</td>
188
<span py:if="line.new_lineno" py:strip="True">
189
<td py:if="line.new_lineno" class="lineno">${line.new_lineno}</td>
190
<td class="diff-${line.new_type}">${line.new_line}</td>
192
<span py:if="not line.new_lineno" py:strip="True">
193
<td py:if="not line.new_lineno" class="lineno-skip">${line.new_lineno}</td>
194
<td class="diff-${line.new_type}-skip">${line.new_line}</td>
197
<tr class="diff-chunk-spacing collapse-file-${util.uniq(uniqs, item.file_id)}-content"> <td colspan="4"> </td> </tr>
199
<tr class="diff-spacing"> <td colspan="4"> </td> </tr>
203
<!-- ! unified diff -->
204
<table class="diff-block collapse-style-unified-content">
205
<span py:strip="True" py:for="item in change.changes.modified">
206
<tr><th class="filename" colspan="4">
207
${collapse_button('file', util.uniq(uniqs, item.file_id), 'table-row')}
208
<a href="${branch.url([ '/annotate', change.revid ], **util.get_context(file_id=item.file_id))}"
209
name="${item.filename}-u" title="Annotate ${item.filename}">${item.filename}</a>
212
<span py:strip="True" py:for="chunk in item.chunks">
213
<tr class="diff-chunk collapse-file-${util.uniq(uniqs, item.file_id)}-content"> <th class="lineno">old</th> <th class="lineno">new</th> <th></th> <th></th> </tr>
214
<tr py:for="line in chunk.diff" class="diff-chunk collapse-file-${util.uniq(uniqs, item.file_id)}-content">
215
<td class="lineno">${line.old_lineno}</td>
216
<td class="lineno">${line.new_lineno}</td>
217
<td class="diff-${line.type} text">${line.line}</td>
220
<tr class="diff-chunk-spacing collapse-file-${util.uniq(uniqs, item.file_id)}-content"> <td colspan="4"> </td> </tr>
222
<tr class="diff-spacing"> <td colspan="4"> </td> </tr>
228
<div py:if="navigation.prev_page_revid or navigation.next_page_revid" class="bar">
232
<a py:if="navigation.prev_page_revid" href="${navigation.prev_page_url}"> < revision ${history.get_revno(navigation.prev_page_revid)} </a>
234
<td class="rbuttons" align="right">
235
<a py:if="navigation.next_page_revid" href="${navigation.next_page_url}"> revision ${history.get_revno(navigation.next_page_revid)} > </a>