@@ -81,16 +81,15 @@ def pygmentize_annotation(filenode, **kw
else:
color_dict[cs] = gen_color()
col = color_dict[cs]
return "color: rgb(%s) ! important;" % (','.join(col))
def url_func(changeset):
return '%s\n' % (link_to(changeset.raw_id,
return '%s\n' % (link_to('r%s:%s' % (changeset.revision, changeset.raw_id),
url('changeset_home', repo_name='test', revision=changeset.raw_id),
title=_('author') + ':%s rev:%s %s' % (changeset.author, changeset.revision,
changeset.message,),
title=_('author') + ':%s - %s' % (changeset.author, changeset.message,),
style=get_color_string(changeset.raw_id)))
return literal(annotate_highlight(filenode, url_func, **kwargs))
def recursive_replace(str, replace=' '):
"""
@@ -25,11 +25,14 @@
%if c.files_list.is_dir():
<%include file='files_browser.html'/>
%else:
<%include file='files_source.html'/>
%endif
<h2><a href="#" onClick="javascript:parent.history.back();" target="main">${_('Go back')}</a> ${_('No files at given path')}: "${c.f_path or "/"}" </h2>
<h2>
<a href="#" onClick="javascript:parent.history.back();" target="main">${_('Go back')}</a>
${_('No files at given path')}: "${c.f_path or "/"}"
</h2>
</div>
</%def>
\ No newline at end of file
@@ -24,15 +24,17 @@
<dl class="overview">
<dt>${_('Revision')}</dt>
<dd>r${c.file.last_changeset.revision}:${c.file.last_changeset._short}</dd>
<dt>${_('Size')}</dt>
<dd>${h.format_byte_size(c.file.size,binary=True)}</dd>
<dt>${_('Options')}</dt>
<dd>${h.link_to(_('source'),
h.url('files_home',repo_name=c.repo_name,revision=c.cur_rev,f_path=c.f_path))} / ${h.link_to(_('raw'),
h.url('files_raw_home',repo_name=c.repo_name,revision=c.cur_rev,f_path=c.f_path))}</dd>
<dd>${h.link_to(_('show source'),
h.url('files_home',repo_name=c.repo_name,revision=c.cur_rev,f_path=c.f_path))}
/ ${h.link_to(_('download as raw'),
h.url('files_raw_home',repo_name=c.repo_name,revision=c.cur_rev,f_path=c.f_path))}
</dd>
</dl>
<div id="body" class="codeblock">
<div class="code-header">
<div class="revision">${c.file.name}@r${c.file.last_changeset.revision}:${c.file.last_changeset._short}</div>
<div class="commit" style="font-size:70%">"${c.file_msg}"</div>
<dd>r${c.files_list.last_changeset.revision}:${c.files_list.last_changeset._short}</dd>
<dd>${h.format_byte_size(c.files_list.size,binary=True)}</dd>
<dd>${h.link_to(_('annotate'),
h.url('files_annotate_home',repo_name=c.repo_name,revision=c.cur_rev,f_path=c.f_path))} / ${h.link_to(_('raw'),
<dd>${h.link_to(_('show annotation'),
h.url('files_annotate_home',repo_name=c.repo_name,revision=c.cur_rev,f_path=c.f_path))}
<dt>${_('History')}</dt>
<dd>
${h.form(h.url('files_diff_home',repo_name=c.repo_name,f_path=c.f_path),method='GET')}
${h.hidden('diff2',c.files_list.last_changeset._short)}
${h.select('diff1','',c.file_history)}
${h.submit('diff','diff')}
Status change: