diff options
author | Eric Wong <e@80x24.org> | 2022-11-28 05:32:09 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2022-11-28 23:38:58 +0000 |
commit | aa82a5a136595d935705e8c9fbffe362e44b8917 (patch) | |
tree | 28f442beb97f6c89192f397c9fb09cc0044a4a53 | |
parent | 715e0c3f93c399e7ae5a6eb608439b527355986a (diff) | |
download | public-inbox-aa82a5a136595d935705e8c9fbffe362e44b8917.tar.gz |
We'll probably save the destination path somewhere, so ensure the path doesn't have redundant slashes and such
-rwxr-xr-x | script/public-inbox-clone | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/script/public-inbox-clone b/script/public-inbox-clone index a11c6874..9a22fa21 100755 --- a/script/public-inbox-clone +++ b/script/public-inbox-clone @@ -37,6 +37,7 @@ defined($dst) or ($dst) = ($url =~ m!/([^/]+)/?\z!); index($dst, "\n") >= 0 and die "`\\n' not allowed in `$dst'"; # n.b. this is still a truckload of code... +require File::Spec; require PublicInbox::LEI; require PublicInbox::LeiExternal; require PublicInbox::LeiMirror; @@ -51,7 +52,7 @@ open $lei->{3}, '.' or die "open . $!"; my $mrr = bless { lei => $lei, src => $url, - dst => $dst, + dst => File::Spec->canonpath($dst), }, 'PublicInbox::LeiMirror'; $? = 0; |