Update.
authorFrançois Fleuret <francois@fleuret.org>
Tue, 23 Jul 2024 05:05:42 +0000 (07:05 +0200)
committerFrançois Fleuret <francois@fleuret.org>
Tue, 23 Jul 2024 05:05:42 +0000 (07:05 +0200)
main.py

diff --git a/main.py b/main.py
index a540cc0..efc40e7 100755 (executable)
--- a/main.py
+++ b/main.py
@@ -239,8 +239,11 @@ def log_string(s):
 
 now = time.strftime("%Y%m%d-%H%M%S", time.localtime())
 
-os.system(f"tar zcvf {args.result_dir}/src-{now}.tgz *.py")
+with open("this_run.sh", "w") as f:
+    f.write(f"{' '.join(sys.argv)}\n")
 
+os.system(f"tar zcvf {args.result_dir}/src-{now}.tgz *.py *.sh")
+exit(0)
 log_string(f"argv {' '.join(sys.argv)}")
 
 for n in vars(args):