aboutsummaryrefslogtreecommitdiffstats
path: root/Web/test.py
diff options
context:
space:
mode:
Diffstat (limited to 'Web/test.py')
-rw-r--r--Web/test.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/Web/test.py b/Web/test.py
index c6f871c..634bc84 100644
--- a/Web/test.py
+++ b/Web/test.py
@@ -1,11 +1,15 @@
-import time, os
+import time, os, sys
from datetime import datetime
+file_name = os.path.basename(sys.argv[0])
+
+file_name = file_name.split(".")[0]
+
now = datetime.now()
current_time = now.strftime("%H:%M:%S")
print("Current Time = " + current_time)
-f = open("Results/results.txt", "w+")
+f = open("Results/" + file_name + "_results", "w+")
f.write("THIS IS RESULTS TEXT\n")
f.write("Current Time = " + current_time)
f.close()