From 5c9d4db85d4d824e81ad9fa8bc96add89ca1e8a1 Mon Sep 17 00:00:00 2001 From: Dariqq <77271900+Dariqq@users.noreply.github.com> Date: Thu, 14 Nov 2024 19:59:55 +0000 Subject: [PATCH] Scripts: `gen-man.py` honors SOURCE_DATE_EPOCH. --- scripts/gen-man.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/scripts/gen-man.py b/scripts/gen-man.py index 77c32f461a..def48b072d 100755 --- a/scripts/gen-man.py +++ b/scripts/gen-man.py @@ -10,8 +10,9 @@ from json import load from datetime import date +from time import time from re import search -from os import path +from os import environ, path ###### Text Decorations Tags ###### @@ -34,7 +35,9 @@ # title (center header) titlePage = "Fastfetch man page" # date (center footer) -todayDate = date.today().strftime("%b %d %Y") # format : "Month (abbreviation) Day Year" +# format : "Month (abbreviation) Day Year" +todayDate = date.fromtimestamp( + int(environ.get("SOURCE_DATE_EPOCH", time()))).strftime("%b %d %Y") # file to fastfetch version (left footer) pathToVersionFile = path.join(pathToCurrentDir, "../CMakeLists.txt")