diff --git a/apps/tools/librelingo_tools/generate.py b/apps/tools/librelingo_tools/generate.py index d3773721da70..96f7b0723417 100755 --- a/apps/tools/librelingo_tools/generate.py +++ b/apps/tools/librelingo_tools/generate.py @@ -34,7 +34,12 @@ def generate_html(start_time, end_time, links, outdir): templates_dir = os.path.join(root, "templates") env = Environment(loader=FileSystemLoader(templates_dir), autoescape=True) template = env.get_template("courses.html") - html = template.render(start_time=start_time, end_time=end_time, links=links) + html = template.render( + start_time=start_time, + end_time=end_time, + links=links, + title="LibreLingo courses", + ) with open(os.path.join(outdir, "index.html"), "w") as fh: fh.write(html) diff --git a/apps/tools/librelingo_tools/templates/central/footer.html b/apps/tools/librelingo_tools/templates/central/footer.html new file mode 100644 index 000000000000..b605728ee26a --- /dev/null +++ b/apps/tools/librelingo_tools/templates/central/footer.html @@ -0,0 +1,2 @@ + + diff --git a/apps/tools/librelingo_tools/templates/central/header.html b/apps/tools/librelingo_tools/templates/central/header.html new file mode 100644 index 000000000000..9035c650fa8f --- /dev/null +++ b/apps/tools/librelingo_tools/templates/central/header.html @@ -0,0 +1,21 @@ + + + + + + + {{ title }} + + + + diff --git a/apps/tools/librelingo_tools/templates/courses.html b/apps/tools/librelingo_tools/templates/courses.html index f8581ebc5075..62f893f88dcf 100644 --- a/apps/tools/librelingo_tools/templates/courses.html +++ b/apps/tools/librelingo_tools/templates/courses.html @@ -1,23 +1,5 @@ - - - - - - - LibreLingo courses - - - +{% include 'central/header.html' %} +

LibreLingo courses

@@ -32,6 +14,5 @@

LibreLingo courses

{% endfor %}
CourseTarget WordsTarget PhrasesSource WordsSource Phrases
Generated at {{ start_time }} Elapsed time: {{ (end_time-start_time).seconds }} seconds
- - +{% include 'central/footer.html' %}