Chop out theoretically dead stuff.
Tomas Doran [Sun, 17 Jan 2010 23:31:42 +0000 (23:31 +0000)]
Again, we're losing functionality for some stuff, but I'd rather remove it,
simplify, then put it back later..

lib/Gitalist/Controller/Root.pm

index 122c1bb..7190b05 100644 (file)
@@ -182,23 +182,6 @@ sub blobdiff : Chained('base') Args(0) {
     unless $c->stash->{no_wrapper};
 }
 
-=head2 commit
-
-Exposes a given commit.
-
-=cut
-
-sub commit : Chained('base') Args(0) {
-  my ( $self, $c ) = @_;
-  my $repository = $c->stash->{Repository};
-  my $commit = $self->_get_object($c);
-  $c->stash(
-      commit      => $commit,
-      diff_tree   => ($repository->diff(commit => $commit))[0],
-      refs      => $repository->references,
-  );
-}
-
 # For legacy support.
 sub history : Chained('base') Args(0) {
     my ( $self, $c ) = @_;
@@ -215,29 +198,6 @@ sub history : Chained('base') Args(0) {
            );
 }
 
-=head2 tree
-
-The tree of a given commit.
-
-=cut
-
-sub tree : Chained('base') Args(0) {
-  my ( $self, $c ) = @_;
-  my $repository = $c->stash->{Repository};
-  my $commit  = $self->_get_object($c, $c->req->param('hb'));
-  my $filename = $c->req->param('f') || '';
-  my $tree    = $filename
-    ? $repository->get_object($repository->hash_by_path($commit->sha1, $filename))
-    : $repository->get_object($commit->tree_sha1)
-  ;
-  $c->stash(
-      commit    => $commit,
-      tree      => $tree,
-      tree_list => [$repository->list_tree($tree->sha1)],
-      path      => $c->req->param('f') || '',
-  );
-}
-
 =head2 reflog
 
 Expose the local reflog. This may go away.