X-Git-Url: https://git.cworth.org/git?p=turbot-web;a=blobdiff_plain;f=html_generator.py;h=0fef3d421c3f1b9158a7e97932f07b43342b24a6;hp=01cecdea7e521c48fb844db5c52e40865d27f58b;hb=HEAD;hpb=46ee43c674ec697c6740b9a531ac0b6ff3a05ab4 diff --git a/html_generator.py b/html_generator.py index 01cecde..f187032 100644 --- a/html_generator.py +++ b/html_generator.py @@ -22,8 +22,6 @@ import sys WEBROOT = "/srv/halibut.cworth.org/www" -website = "https://halibut.cworth.org/" -#change this if we're using AWS or some other subdomain instead def hunt_file(hunt, name): """Return a path file 'name' within the given hunt. @@ -32,6 +30,12 @@ def hunt_file(hunt, name): return "{}/{}/{}".format(WEBROOT, hunt['channel_id'], name) +def internal_link(hunt, name): + """Returns a path for a link on this site.""" + + # Just generate a relative link, (which is just the name itself) + return "{}".format(name) + def filename_from_name(name): """Returns a string derived from name, but with all spaces and slashes replaced with underscores, (for making a clean filename)""" @@ -141,6 +145,7 @@ def overview(hunt, puzzles, rounds): '\n', ' \n', ' \n', + ' \n', '\n', ' \n', ' \n' '\n', - '
\n' - ' Hunt Overview' - ' All Puzzles\n' - ' Unsolved\n' - ' Solved\n' - '
\n' + '
\n', + ' Hunt Overview', + ' All Puzzles\n', + ' Unsolved\n', + ' Solved\n', + ' Turbot Docs\n' + '
\n', '\n',] columns = ['
\n'] expanding = [] @@ -183,7 +189,7 @@ def overview(hunt, puzzles, rounds): expanding += [ '