Commit | Line | Data |
e172b6b8 |
1 | [%- IF is_image -%] |
2 | <div class='blob'><img src="[% c.uri_for_action('/ref/raw', c.req.captures, filename) %]" title="[% filename %]"></div> |
3 | [%- ELSIF is_binary -%] |
4 | <div class='blob'>This is a binary file which won't render natively on the web, but you can get it here all the same: <a href="[% c.uri_for_action('/ref/raw', c.req.captures, filename) %]" title="[% filename %]">[% filename %]</a></div> |
5 | [%- ELSE -%] |
606ffc33 |
6 | [%- USE UTF8Decode -%] |
18add14a |
7 | [%- IF mangled; INCLUDE inc/syntax_highlight_css.tt2; END -%] |
8 | [% FOR line IN blob.split("\n") %] |
9 | <tr class=''> |
10 | <td nowrap class='lineno' id='l[% loop.index+1 %]'><tt><a href='[% c.uri_for_action('/ref/blame', [Repository.name, info.commit.sha1], filename.to_path ) %]#l[% lopo.index %]'>[% loop.index+1 %]</a></tt></td> |
11 | <td nowrap class='data'><pre>[%- |
12 | IF mangled; line; ELSE; line | utf8_decode | html; END |
13 | -%]</pre></td> |
14 | </tr> |
15 | [% END %] |
e172b6b8 |
16 | [%- END -%] |