Skip to content

Commit

Permalink
htmlify: Always explicitly link to the gh repo in the footer
Browse files Browse the repository at this point in the history
Closes #85.
  • Loading branch information
moritz committed May 24, 2015
1 parent 5a2cebc commit 90b5c64
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lib/Pod/Htmlify.pm6
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,12 @@ sub footer-html($pod-path) is export {
my $footer = slurp 'template/footer.html';
$footer.subst-mutate(/DATETIME/, ~DateTime.now);
my $pod-url;
my $gh-link = q[<a href='https://github.com/perl6/doc'>perl6/doc on GitHub</a>];
if $pod-path eq "unknown" {
$pod-url = "the sources at <a href='https://github.com/perl6/doc'>perl6/doc on GitHub</a>";
$pod-url = "the sources at $gh-link";
}
else {
$pod-url = "<a href='https://github.com/perl6/doc/raw/master/lib/$pod-path'>$pod-path\</a\>";
$pod-url = "<a href='https://github.com/perl6/doc/raw/master/lib/$pod-path'>$pod-path\</a\> from $gh-link";
}
$footer.subst-mutate(/SOURCEURL/, $pod-url);

Expand Down

0 comments on commit 90b5c64

Please sign in to comment.