From e34644d6a68dba51bfa45a107c2b93138b045872 Mon Sep 17 00:00:00 2001 From: Thomas Mangin Date: Mon, 15 Jul 2024 21:16:29 +0100 Subject: [PATCH] use file date and not clock --- src/exabgp/version.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/exabgp/version.py b/src/exabgp/version.py index 1c8b22414..6f68ffa93 100644 --- a/src/exabgp/version.py +++ b/src/exabgp/version.py @@ -2,8 +2,11 @@ import sys from datetime import datetime -commit = "99de31e8" -release = "5.0.0-%s+uncontrolled" % datetime.now().strftime('%Y%m%d') +modification_time = modification_time = os.path.getmtime(os.path.abspath(__file__)) +date = datetime.fromtimestamp(modification_time) + +commit = "unset" +release = "5.0.0-%s+uncontrolled" % date.strftime('%Y%m%d') json = "5.0.0" text = "5.0.0" version = os.environ.get('EXABGP_VERSION', release)