From: Dan Brook Date: Fri, 20 Nov 2009 12:18:09 +0000 (+0000) Subject: Added stubs for further missing actions. X-Git-Tag: 0.000000_01~17 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=77730637cfd57f0e438643ed9f9aab53f307c741;p=catagits%2FGitalist.git Added stubs for further missing actions. Dropped the now redundant Gitalist/Utils.pm. --- diff --git a/lib/Gitalist/Controller/Root.pm b/lib/Gitalist/Controller/Root.pm index d295155..4f388ef 100644 --- a/lib/Gitalist/Controller/Root.pm +++ b/lib/Gitalist/Controller/Root.pm @@ -4,10 +4,6 @@ use namespace::autoclean; BEGIN { extends 'Catalyst::Controller' } -# -# Sets the actions in this controller to be registered with no prefix -# so they function identically to actions created in MyApp.pm -# __PACKAGE__->config->{namespace} = ''; use IO::Capture::Stdout; @@ -531,6 +527,23 @@ sub auto : Private { ); } +sub tags : Local { + # FIXME - implement snapshot + Carp::croak "Not implemented."; +} +sub project_index : Local { + # FIXME - implement snapshot + Carp::croak "Not implemented."; +} +sub opml : Local { + # FIXME - implement snapshot + Carp::croak "Not implemented."; +} +sub blame : Local { + # FIXME - implement snapshot + Carp::croak "Not implemented."; +} + =head2 end Attempt to render a view, if needed. diff --git a/lib/Gitalist/Util.pm b/lib/Gitalist/Util.pm deleted file mode 100644 index cbaad56..0000000 --- a/lib/Gitalist/Util.pm +++ /dev/null @@ -1,28 +0,0 @@ -package Gitalist::Util; - -use Sub::Exporter -setup => { - exports => ['to_utf8'] -}; - -=pod - -=head1 NAME - -Gitalist::Util - Your usual catch all utility function package. - -=cut - -# decode sequences of octets in utf8 into Perl's internal form, -# which is utf-8 with utf8 flag set if needed. gitweb writes out -# in utf-8 thanks to "binmode STDOUT, ':utf8'" at beginning -sub to_utf8 { - my $str = shift; - if (utf8::valid($str)) { - utf8::decode($str); - return $str; - } else { - return decode($fallback_encoding, $str, Encode::FB_DEFAULT); - } -} - -1; diff --git a/root/static/css/site.css b/root/static/css/site.css index 69b14c8..fbcb637 100644 --- a/root/static/css/site.css +++ b/root/static/css/site.css @@ -234,21 +234,22 @@ span.refs a { } a.rss_logo { - float: right; - padding: 3px 0px; - width: 35px; - line-height: 10px; - border: 1px solid; - border-color: #fcc7a5 #7d3302 #3e1a01 #ff954e; - color: #ffffff; - background-color: #ff6600; - font-weight: bold; - font-family: sans-serif; - font-size: 70%; - text-align: center; - text-decoration: none; + float: right; + padding: 3px 0px; + width: 35px; + line-height: 10px; + border: 1px solid; + border-color: #fcc7a5 #7d3302 #3e1a01 #ff954e; + color: #ffffff; + background-color: #ff6600; + font-weight: bold; + font-family: sans-serif; + font-size: 70%; + font-style: normal; + text-align: center; + text-decoration: none; } a.rss_logo:hover { - background-color: #ee5500; + background-color: #ee5500; } diff --git a/t/03legacy_uri.t b/t/03legacy_uri.t index a2722a1..2e909bb 100644 --- a/t/03legacy_uri.t +++ b/t/03legacy_uri.t @@ -244,6 +244,26 @@ TODO: { local $TODO = 'The tags action is yet to be implemented'; test('/', 'a=tags'); } +TODO: { + local $TODO = 'The blame action is yet to be implemented'; + + test('/', 'a=blame;f=dir1/file2;h=257cc5642cb1a054f08cc83f2d943e56fd3ebe99;hb=36c6c6708b8360d7023e8a1649c45bcf9b3bd818'); + test('/', 'a=blame;f=dir1/file2;h=257cc5642cb1a054f08cc83f2d943e56fd3ebe99;hb=HEAD'); + test('/', 'a=blame;f=dir1/file2;h=257cc5642cb1a054f08cc83f2d943e56fd3ebe99;hb=master'); + test('/', 'a=blame;f=dir1/file2;h=257cc5642cb1a054f08cc83f2d943e56fd3ebe99;hb=refs/heads/master'); + test('/', 'a=blame;f=dir1/file2;hb=36c6c6708b8360d7023e8a1649c45bcf9b3bd818'); + test('/', 'a=blame;f=file1;h=257cc5642cb1a054f08cc83f2d943e56fd3ebe99'); + test('/', 'a=blame;f=file1;h=257cc5642cb1a054f08cc83f2d943e56fd3ebe99;hb=257cc5642cb1a054f08cc83f2d943e56fd3ebe99'); + test('/', 'a=blame;f=file1;h=257cc5642cb1a054f08cc83f2d943e56fd3ebe99;hb=3bc0634310b9c62222bb0e724c11ffdfb297b4ac'); + test('/', 'a=blame;f=file1;h=5716ca5987cbf97d6bb54920bea6adde242d87e6;hb=36c6c6708b8360d7023e8a1649c45bcf9b3bd818'); + test('/', 'a=blame;f=file1;h=5716ca5987cbf97d6bb54920bea6adde242d87e6;hb=3f7567c7bdf7e7ebf410926493b92d398333116e'); + test('/', 'a=blame;f=file1;h=5716ca5987cbf97d6bb54920bea6adde242d87e6;hb=5716ca5987cbf97d6bb54920bea6adde242d87e6'); + test('/', 'a=blame;f=file1;h=5716ca5987cbf97d6bb54920bea6adde242d87e6;hb=HEAD'); + test('/', 'a=blame;f=file1;h=5716ca5987cbf97d6bb54920bea6adde242d87e6;hb=master'); + test('/', 'a=blame;f=file1;h=5716ca5987cbf97d6bb54920bea6adde242d87e6;hb=refs/heads/master'); + test('/', 'a=blame;f=file1;hb=3bc0634310b9c62222bb0e724c11ffdfb297b4ac'); + test('/', 'a=blame;f=file1;hb=3f7567c7bdf7e7ebf410926493b92d398333116e'); +} done_testing;