From 5557c83624b9eb4d1175e32a6ffd58541d1bcb56 Mon Sep 17 00:00:00 2001 From: Nils <> Date: Sun, 3 May 2020 18:52:27 +0200 Subject: [PATCH] Add last generated date to index.html --- directcontent/index | 5 +++++ index2dataindex.py | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/directcontent/index b/directcontent/index index 090ce48..08c4ce8 100644 --- a/directcontent/index +++ b/directcontent/index @@ -4,6 +4,10 @@
+

+ Last website update: PYREPLACE_DATE +

+

Laborejo Software Suite is a group of programs to make music (and also the name of its main program). Everything is free in every sense of the word: free of cost, free to share and use, free of @@ -25,5 +29,6 @@

You can write an e-mail to info@laborejo.org for any comment or question.

For bugs and issues a service has been set up that works without registration. Thank you for your help to make our software better by reporting bugs.

+
diff --git a/index2dataindex.py b/index2dataindex.py index 7986d2a..a40582f 100755 --- a/index2dataindex.py +++ b/index2dataindex.py @@ -21,10 +21,13 @@ The image file is a static file. At this point in time manually copied into the """ import sys +import datetime +today_str = str(datetime.date.today()) projects = sys.argv[1:] #exclude our own filename assert projects + oneliners = "" for project in projects: config = __import__(f"temp.{project}.engine.config", fromlist=["METADATA"]) @@ -36,6 +39,7 @@ for project in projects: with open("directcontent/index", "r") as f: template = f.read() template = template.replace("PYREPLACE_ONELINERS", oneliners) + template = template.replace("PYREPLACE_DATE", today_str) print (template) #stdout. our job is done