From dbe7f3fcb8fa71d14bb27a9963d841cc12007117 Mon Sep 17 00:00:00 2001 From: advaithm Date: Sun, 4 Apr 2021 19:20:08 +0530 Subject: Fixed issue with no network configueration --- examples/guided.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'examples/guided.py') diff --git a/examples/guided.py b/examples/guided.py index 1a1cf84c..ee8c5d57 100644 --- a/examples/guided.py +++ b/examples/guided.py @@ -317,6 +317,9 @@ def perform_installation(device, boot_partition, language, mirrors): # Perform a copy of the config if archinstall.arguments.get('nic', None) == 'Copy ISO network configuration to installation': installation.copy_ISO_network_config(enable_services=True) # Sources the ISO network configuration to the install medium. + elif archinstall.arguments.get('nic',None) == None: + #skip if we don't have a network + pass elif archinstall.arguments.get('nic',{}).get('NetworkManager',False): installation.add_additional_packages("networkmanager") installation.enable_service('NetworkManager.service') @@ -326,7 +329,6 @@ def perform_installation(device, boot_partition, language, mirrors): installation.enable_service('systemd-networkd') installation.enable_service('systemd-resolved') - if archinstall.arguments.get('packages', None) and archinstall.arguments.get('packages', None)[0] != '': installation.add_additional_packages(archinstall.arguments.get('packages', None)) -- cgit v1.2.3-70-g09d2 From e2a6a85d66ef0d43c5bb941d9ec945c854f45849 Mon Sep 17 00:00:00 2001 From: advaithm Date: Mon, 5 Apr 2021 20:47:42 +0530 Subject: Revert "Fixed issue with no network configueration" This reverts commit dbe7f3fcb8fa71d14bb27a9963d841cc12007117. --- examples/guided.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'examples/guided.py') diff --git a/examples/guided.py b/examples/guided.py index ee8c5d57..1a1cf84c 100644 --- a/examples/guided.py +++ b/examples/guided.py @@ -317,9 +317,6 @@ def perform_installation(device, boot_partition, language, mirrors): # Perform a copy of the config if archinstall.arguments.get('nic', None) == 'Copy ISO network configuration to installation': installation.copy_ISO_network_config(enable_services=True) # Sources the ISO network configuration to the install medium. - elif archinstall.arguments.get('nic',None) == None: - #skip if we don't have a network - pass elif archinstall.arguments.get('nic',{}).get('NetworkManager',False): installation.add_additional_packages("networkmanager") installation.enable_service('NetworkManager.service') @@ -329,6 +326,7 @@ def perform_installation(device, boot_partition, language, mirrors): installation.enable_service('systemd-networkd') installation.enable_service('systemd-resolved') + if archinstall.arguments.get('packages', None) and archinstall.arguments.get('packages', None)[0] != '': installation.add_additional_packages(archinstall.arguments.get('packages', None)) -- cgit v1.2.3-70-g09d2 From 463d1b5fd37db1435f15987929963ee2f2c2dc02 Mon Sep 17 00:00:00 2001 From: advaithm Date: Mon, 5 Apr 2021 20:58:38 +0530 Subject: add shell drop for i3 and i3-gaps --- examples/guided.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'examples/guided.py') diff --git a/examples/guided.py b/examples/guided.py index 1a1cf84c..74db0ce5 100644 --- a/examples/guided.py +++ b/examples/guided.py @@ -344,7 +344,11 @@ def perform_installation(device, boot_partition, language, mirrors): if (root_pw := archinstall.arguments.get('!root-password', None)) and len(root_pw): installation.user_set_pw('root', root_pw) - + if archinstall.arguments.get('profile', None) == "i3-wm" or archinstall.arguments.get('profile', None) == "i3-gaps": + print("the installation of i3/i3-gaps does not conatain any configuerations for the wm. in this shell you should add your configuerations") + installation.arch_chroot("bash") ask_user_questions() perform_installation_steps() + + \ No newline at end of file -- cgit v1.2.3-70-g09d2 From 947700a605b5c9a066f29b9a51e36a079ccfd45a Mon Sep 17 00:00:00 2001 From: advaithm Date: Mon, 5 Apr 2021 21:03:56 +0530 Subject: use subprocess to launch the shell --- examples/guided.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'examples/guided.py') diff --git a/examples/guided.py b/examples/guided.py index 74db0ce5..fd4ee906 100644 --- a/examples/guided.py +++ b/examples/guided.py @@ -346,7 +346,7 @@ def perform_installation(device, boot_partition, language, mirrors): installation.user_set_pw('root', root_pw) if archinstall.arguments.get('profile', None) == "i3-wm" or archinstall.arguments.get('profile', None) == "i3-gaps": print("the installation of i3/i3-gaps does not conatain any configuerations for the wm. in this shell you should add your configuerations") - installation.arch_chroot("bash") + subprocess.check_call("arch-chroot /mnt") ask_user_questions() perform_installation_steps() -- cgit v1.2.3-70-g09d2 From 9404dbe967beaa060101c4d53758ee308f754740 Mon Sep 17 00:00:00 2001 From: advaithm Date: Mon, 5 Apr 2021 21:05:15 +0530 Subject: Update guided.py --- examples/guided.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'examples/guided.py') diff --git a/examples/guided.py b/examples/guided.py index fd4ee906..b3c5ca04 100644 --- a/examples/guided.py +++ b/examples/guided.py @@ -1,4 +1,4 @@ -import getpass, time, json, sys, signal, os +import getpass, time, json, sys, signal, os, subprocess import archinstall from archinstall.lib.hardware import hasUEFI -- cgit v1.2.3-70-g09d2