X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FGitalist%2FController%2FRoot.pm;h=f4ab6db8e745749b0577e75cbe9ccabfe8c29332;hb=ea19a20c43ebc1365ddbbfca835041614f50621b;hp=f93895a427454284ef9632a09014f5592c49c64f;hpb=349064eda3f9bdd9354a3301cc51e11952632708;p=catagits%2FGitalist.git diff --git a/lib/Gitalist/Controller/Root.pm b/lib/Gitalist/Controller/Root.pm index f93895a..f4ab6db 100644 --- a/lib/Gitalist/Controller/Root.pm +++ b/lib/Gitalist/Controller/Root.pm @@ -117,6 +117,22 @@ sub heads : Local { ); } +=head2 tags + +The current list of tags in the repo. + +=cut + +sub tags : Local { + my ( $self, $c ) = @_; + my $project = $c->stash->{Project}; + $c->stash( + commit => $self->_get_object($c), + tags => $project->tags, + action => 'tags', + ); +} + =head2 blob The blob action i.e the contents of a file. @@ -334,6 +350,12 @@ sub reflog : Local { ); } +=head2 search + +The action for the search form. + +=cut + sub search : Local { my($self, $c) = @_; $c->stash(current_action => 'GitRepos'); @@ -359,11 +381,23 @@ sub search : Local { ); } +=head2 search_help + +Provides some help for the search form. + +=cut + sub search_help : Local { my ($self, $c) = @_; $c->stash(template => 'search_help.tt2'); } +=head2 atom + +Provides an atom feed for a given project. + +=cut + sub atom : Local { my($self, $c) = @_; @@ -395,6 +429,12 @@ sub atom : Local { $c->response->status(200); } +=head2 rss + +Provides an RSS feed for a given project. + +=cut + sub rss : Local { my ($self, $c) = @_; @@ -430,11 +470,23 @@ sub rss : Local { $c->response->status(200); } +=head2 patch + +A raw patch for a given commit. + +=cut + sub patch : Local { my ($self, $c) = @_; $c->detach('patches', [1]); } +=head2 patches + +The patcheset for a given commit ??? + +=cut + sub patches : Local { my ($self, $c, $count) = @_; $count ||= Gitalist->config->{patches}{max}; @@ -446,6 +498,12 @@ sub patches : Local { $c->response->status(200); } +=head2 snapshot + +Provides a snapshot of a given commit. + +=cut + sub snapshot : Local { my ($self, $c) = @_; my $format = $c->req->param('sf') || 'tgz'; @@ -502,10 +560,6 @@ sub auto : Private { ); } -sub tags : Local { - # FIXME - implement snapshot - Carp::croak "Not implemented."; -} sub project_index : Local { # FIXME - implement snapshot Carp::croak "Not implemented.";