While PublicInbox::WWW URLs have a trailing slash in them
for compatibility with static web server mirrors, URLs
intended for `git clone' don't benefit from this and the
trailing `/' just looks awkward.
---
 lib/PublicInbox/LeiMirror.pm | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lib/PublicInbox/LeiMirror.pm b/lib/PublicInbox/LeiMirror.pm
index cf4e58f1..5b7cf9e6 100644
--- a/lib/PublicInbox/LeiMirror.pm
+++ b/lib/PublicInbox/LeiMirror.pm
@@ -533,6 +533,8 @@ sub clone_v1 {
        my $lei = $self->{lei};
        my $curl = $self->{curl} //= PublicInbox::LeiCurl->new($lei) or return;
        my $uri = URI->new($self->{cur_src} // $self->{src});
+       my $path = $uri->path;
+       $path =~ s!/*\z!! and $uri->path($path);
        defined($lei->{opt}->{epoch}) and
                die "$uri is a v1 inbox, --epoch is not supported\n";
        $self->{-torsocks} //= $curl->torsocks($lei, $uri) or return;

Reply via email to