From: Tomas Doran Date: Sun, 17 Jan 2010 19:05:41 +0000 (+0000) Subject: Make display of heads work X-Git-Tag: 0.000006_01~1^2~106 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=103b1b992ac192806248eabc64d16aca0f585e2e;p=catagits%2FGitalist.git Make display of heads work --- diff --git a/lib/Gitalist/Controller/Repository.pm b/lib/Gitalist/Controller/Repository.pm index 5015ae2..2560a98 100644 --- a/lib/Gitalist/Controller/Repository.pm +++ b/lib/Gitalist/Controller/Repository.pm @@ -30,6 +30,14 @@ sub shortlog : Chained('find') Args(0) { $c->forward('/shortlog'); } +sub heads : Chained('find') Args(0) { + my ($self, $c) = @_; + $c->stash( + no_wrapper => 1, + heads => $c->stash->{Repository}->heads, + ); +} + sub log : Chained('find') Args(0) { my ($self, $c) = @_; $c->stash(template => 'log.tt2'); diff --git a/root/heads.tt2 b/root/heads.tt2 index baa8e4b..14f3b90 100644 --- a/root/heads.tt2 +++ b/root/heads.tt2 @@ -5,5 +5,5 @@ [% Repository.name %] - [% INCLUDE '_heads.tt2' %] + [% INCLUDE 'repository/heads.tt2' %] diff --git a/root/_heads.tt2 b/root/repository/heads.tt2 similarity index 100% rename from root/_heads.tt2 rename to root/repository/heads.tt2 diff --git a/root/summary.tt2 b/root/summary.tt2 index be4b3e1..2b318c5 100644 --- a/root/summary.tt2 +++ b/root/summary.tt2 @@ -18,5 +18,5 @@ [% INCLUDE '_shortlog.tt2' %]

branches

- [% INCLUDE '_heads.tt2' %] + [% INCLUDE 'repository/heads.tt2' %] diff --git a/root/tags.tt2 b/root/tags.tt2 index 6f47285..3f888d3 100644 --- a/root/tags.tt2 +++ b/root/tags.tt2 @@ -4,5 +4,5 @@ [% Repository.name %] - [% INCLUDE '_heads.tt2' heads = tags %] + [% INCLUDE 'repository/heads.tt2' heads = tags %]