summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxengineering <mail2xengineering@protonmail.com>2019-10-13 14:13:21 +0200
committerxengineering <mail2xengineering@protonmail.com>2019-10-13 14:13:21 +0200
commitdb9decc0f0450657d4e45aa7fe5bc15fe0292a74 (patch)
tree30b36ddf1abc9a5f19000ab7efe1cdc3b9212528
parent5119563581a64cebaf8011380b6706ee7eb822b3 (diff)
downloadarchinstall-db9decc0f0450657d4e45aa7fe5bc15fe0292a74.tar
archinstall-db9decc0f0450657d4e45aa7fe5bc15fe0292a74.tar.zst
archinstall-db9decc0f0450657d4e45aa7fe5bc15fe0292a74.zip
Test run for config in new_archinstall.sh.
-rw-r--r--bin/config_writer.py12
-rw-r--r--new_archinstall.sh3
2 files changed, 13 insertions, 2 deletions
diff --git a/bin/config_writer.py b/bin/config_writer.py
index b0963eb..43f6764 100644
--- a/bin/config_writer.py
+++ b/bin/config_writer.py
@@ -24,15 +24,25 @@
import sys
+import json
log_file_path = sys.argv[1]
+config_file_path = sys.argv[2]
def output(text):
print(text)
with open(log_file_path, 'a') as f:
f.write(text)
+ f.write("")
-output("Hello world!")
+config = {}
+
+
+config["test"] = "testing"
+config["test2"] = 2
+
+config_json = json.dumps(config)
+output(config_json)
diff --git a/new_archinstall.sh b/new_archinstall.sh
index f231dfd..bdfc500 100644
--- a/new_archinstall.sh
+++ b/new_archinstall.sh
@@ -117,7 +117,8 @@ output "Generating config ..."
script_path=$SCRIPT_BASE_PATH
script_path+="config_writer.py"
-python $script_path $LOG_FILE_PATH
+python $script_path $LOG_FILE_PATH $CONFIG_FILE_PATH
+output "Generated config - OK"
# Generate new system ...