]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/WwwCoderepo.pm
www_coderepo: wire up /$CODEREPO/$OID/s/ endpoint
[public-inbox.git] / lib / PublicInbox / WwwCoderepo.pm
index 4b1a4f9baeb2b00ad03e84a35122605e58ecaa81..e0fc90459d209b1a7299a550f09235723880d360 100644 (file)
@@ -171,6 +171,10 @@ sub srv { # endpoint called by PublicInbox::WWW
        }
        $path_info =~ m!\A/(.+?)/\z! and
                ($ctx->{git} = $self->{"\0$1"}) and return summary($self, $ctx);
+       $path_info =~ m!\A/(.+?)/([a-f0-9]+)/s/\z! and
+                       ($ctx->{git} = $self->{"\0$1"}) and
+               return PublicInbox::ViewVCS::show($ctx, $2);
+
        if ($path_info =~ m!\A/(.+?)\z! and ($git = $self->{"\0$1"})) {
                my $qs = $ctx->{env}->{QUERY_STRING};
                my $url = $git->base_url($ctx->{env});