sitemap: prefer https protocol for absolute site references
[sheet.git] / index.plp
index 8ce5b8cdd75c511de2877ee4228f4d1f8084d694..690902542701d9eb01aea324ef1fc840ea901cfe 100644 (file)
--- a/index.plp
+++ b/index.plp
@@ -2,6 +2,7 @@
 
 Html({
        title => 'cheat sheets',
+       canonical => '/',
        version => '1.17',
        description => [
                "Cheat sheets summarising various software programs and standards.",
@@ -34,7 +35,9 @@ if (open my $log, '<', 'UPDATE') {{
        EscapeHTML $line;
        my ($date, $subject) = split /[\t\n]/, $line;
        $date =~ s/ \K/<small>/ and $date .= '</small>';
-       $subject =~ s{\A(\w+)(?=: )}{showlink($1, -e "$1.plp" && "/$1")}e;
+       $subject =~ s{\A (\w+) (?= (?:/\w+)* :\h )}{
+               showlink($1, -e "$1.plp" && "/$1");
+       }ex;
        say "<p><strong>Last update</strong>: $date $subject</p>";
 }}