From ac99346ac9cf7b74488e90bb1f85452953aeb2ef Mon Sep 17 00:00:00 2001 From: Johannes Findeisen Date: Thu, 23 Feb 2023 23:12:48 +0100 Subject: [PATCH] Adde files/receipes.py for code snippet storage. (0.21) --- .gitignore | 1 + files/receipes.py | 4 ++++ 2 files changed, 5 insertions(+) create mode 100644 files/receipes.py diff --git a/.gitignore b/.gitignore index c790066..a7f2154 100644 --- a/.gitignore +++ b/.gitignore @@ -2,6 +2,7 @@ etc.local/ log/*.log log/*.log.* +tmp.py # ---> Python # Byte-compiled / optimized / DLL files diff --git a/files/receipes.py b/files/receipes.py new file mode 100644 index 0000000..a0a5a97 --- /dev/null +++ b/files/receipes.py @@ -0,0 +1,4 @@ +# get system timezone name +# https://stackoverflow.com/questions/1111056/get-time-zone-information-of-the-system-in-python +import datetime +tz_string = datetime.datetime.now(datetime.timezone.utc).astimezone().tzname()