Removed the gitweb shim and its dependency.
Dan Brook [Fri, 20 Nov 2009 12:33:38 +0000 (12:33 +0000)]
Makefile.PL
lib/Gitalist/Controller/Root.pm

index 920142c..20d6539 100644 (file)
@@ -49,7 +49,6 @@ requires 'File::Copy::Recursive';
 requires 'File::Stat::ModeString';
 requires 'File::Which';
 requires 'HTML::Entities';
-requires 'IO::Capture::Stdout';
 requires 'IPC::Run';
 requires 'List::MoreUtils';
 requires 'Path::Class' => '0.17';
index e6d9edb..f93895a 100644 (file)
@@ -6,7 +6,6 @@ BEGIN { extends 'Catalyst::Controller' }
 
 __PACKAGE__->config->{namespace} = '';
 
-use IO::Capture::Stdout;
 use Sys::Hostname ();
 use XML::Atom::Feed;
 use XML::Atom::Entry;
@@ -24,40 +23,6 @@ Gitalist::Controller::Root - Root Controller for Gitalist
 
 =cut
 
-=head2 index
-
-=cut
-
-=head2 run_gitweb
-
-The C<gitweb> shim. It should now only be explicitly accessible by
-modifying the URL.
-
-=cut
-
-sub run_gitweb {
-  my ( $self, $c ) = @_;
-
-  # XXX A slippery slope to be sure.
-  if($c->req->param('a')) {
-    my $capture = IO::Capture::Stdout->new();
-    $capture->start();
-    eval {
-      my $action = gitweb::main($c);
-      $action->();
-    };
-    $capture->stop();
-
-    use Data::Dumper;
-    die Dumper($@)
-      if $@;
-
-    my $output = join '', $capture->read;
-    $c->stash->{gitweb_output} = $output;
-    $c->stash->{template} = 'gitweb.tt2';
-  }
-}
-
 sub _get_object {
   my($self, $c, $haveh) = @_;