Skip to content

Commit

Permalink
Improves document name for #2924
Browse files Browse the repository at this point in the history
  • Loading branch information
JJ committed Jul 30, 2019
1 parent 86559aa commit b86b6ab
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions util/issue-with-all-pod6.p6
Expand Up @@ -7,12 +7,13 @@ my @docs = qx/git ls-files | grep "\.pod6"/.lines;
for @docs -> $d {
my $repo-path = S[doc] = '/perl6/doc/blob/master/doc' with $d;
my $web-path = S[doc] = 'https://docs.perl6.org' with $d;
my $doc-name = $d.split("/")[*-1].split(".")[0];
if $web-path ~~ /Type/ {
my @fragments = $web-path.split("/Type/");
$web-path = @fragments[0] ~ "/type/" ~ @fragments[1].trans( ['/'] => ['::'] );
$doc-name = @fragments[1].trans( ['/'] => ['::'] ).split(".")[0];
$web-path = @fragments[0] ~ "/type/" ~ $doc-name;
}
my $doc-name = $d.split("/")[*-1].split(".")[0];
$web-path .= trans( [ "Language", "Programs", ".pod6" ] =>
[ "language", "programs", ''] );
$web-path .= trans( [ "Language", "Programs" ] =>
[ "language", "programs" ] );
say "* [ ] $doc-name [file]($repo-path), [generated]($web-path)";
}

0 comments on commit b86b6ab

Please sign in to comment.