diff options
author | bnewbold <bnewbold@manus.(none)> | 2007-02-20 02:21:25 -0800 |
---|---|---|
committer | bnewbold <bnewbold@manus.(none)> | 2007-02-20 02:21:25 -0800 |
commit | 3d203c153301d4dd9c3285e7dea86ee09eb3b0c5 (patch) | |
tree | 47bf5bb676c5f25def0a4a37852c1783961a03e6 /bn_django/git_browse/templates | |
parent | 566473abe7aac915429a633e996bdb719f1a308b (diff) | |
download | bnewnet-3d203c153301d4dd9c3285e7dea86ee09eb3b0c5.tar.gz bnewnet-3d203c153301d4dd9c3285e7dea86ee09eb3b0c5.zip |
mid-progress, work on git-browser
fan is dying, more work to do though!
TODO: seperate style for git_browser, use "block.super"
Diffstat (limited to 'bn_django/git_browse/templates')
-rw-r--r-- | bn_django/git_browse/templates/git_browse/obj.html | 2 | ||||
-rw-r--r-- | bn_django/git_browse/templates/git_browse/repository_info.html | 52 |
2 files changed, 51 insertions, 3 deletions
diff --git a/bn_django/git_browse/templates/git_browse/obj.html b/bn_django/git_browse/templates/git_browse/obj.html index be0b556..0170eab 100644 --- a/bn_django/git_browse/templates/git_browse/obj.html +++ b/bn_django/git_browse/templates/git_browse/obj.html @@ -3,7 +3,7 @@ {% block gitbrowse %} {% if contents %} <h3>Object sha1 hash: {{ hash }}<br /> - Size: {{ size }} kB<br /> + Size: {{ size|filesizeformat }}<br /> Type: "{{ type }}"</h3> <pre>{{ contents }}</pre> {% else %} diff --git a/bn_django/git_browse/templates/git_browse/repository_info.html b/bn_django/git_browse/templates/git_browse/repository_info.html index 72f30b1..b3028a2 100644 --- a/bn_django/git_browse/templates/git_browse/repository_info.html +++ b/bn_django/git_browse/templates/git_browse/repository_info.html @@ -5,7 +5,55 @@ {% if shortlog %} <h3>Shortlog (<a href="/code/{{object.slug}}/log/">full log</a>)</h3> <pre>{{ shortlog }}</pre> -<h3>Filelist (<a href="/code/{{object.slug}}/tree/">browse</a>)</h3> -<pre>{{ filelist }}</pre> +<h3>Heads (<a href="/code/{{object.slug}}/tree/">browse</a>)</h3> +{% if heads %} +<table class="gitbrowser"> +{% for h in heads.iteritems %} +<tr> + <td class="head"> + <a href="/code/{{object.slug}}/commit/{{ h.1 }}" class="subtle"> + {{ h.0 }}</a></td> + <td class="links"> + <a href="/code/{{object.slug}}/commit/{{ h.1 }}">commit</a> | + <a href="/code/{{object.slug}}/commit/{{ h.1 }}/zip"> zip </a></td> + <td class="commit_hash"> + <a href="/code/{{object.slug}}/obj/{{ h.1 }}" class="subtle"> + {{ h.1 }}</a> + {% for t in tags.iteritems %} + {% ifequal h.1 t.1 %} + <a href="/code/{{object.slug}}/tag/{{ h.1 }}/" class="tag"> + [{{ t.0 }}]</a> + {% endifequal %}{% endfor %} + </td></tr> +{% endfor %} +</table> +{% else %}No heads!{% endif %} +<h3>Tags (<a href="/code/{{object.slug}}/tree/">browse</a>)</h3> +{% if tags %} +<table class="gitbrowser"> +{% for t in tags.iteritems %} +<tr> + <td class="tag"> + <a href="/code/{{object.slug}}/tag/{{ h.1 }}" class="subtle"> + {{ t.0 }}</a></td> + <td class="links"> + <a href="/code/{{object.slug}}/tag/{{ t.1 }}">tag</a> | + <a href="/code/{{object.slug}}/commit/{{ t.1 }}">commit</a> | + <a href="/code/{{object.slug}}/commit/{{ t.1 }}/zip"> zip </a></td> + <td class="commit_hash"> + <a href="/code/{{object.slug}}/obj/{{ t.1 }}" class="subtle"> + <span class="hash">{{ t.1 }}</span></a> + {% for t in tags.iteritems %} + {% ifequal h.1 t.1 %} + <a href="/code/{{object.slug}}/tag/{{ h.1 }}/" class="tag"> + [{{ t.0 }}]</a> + {% endifequal %}</td></tr> + {% endfor %} +{% endfor %} +</table> +{% else %}No tags!{% endif %} +<h3>Filelist (<a href="/code/{{object.slug}}/tree/">browse tree</a>)</h3> +{% if filelist %} <pre class="large">{{ filelist }}</pre> +{% else %}No files!{% endif %} {% endif %} {% endblock %} |