From 5cb3b0d176fff9d2c2fb814530b29eca5819fe8e Mon Sep 17 00:00:00 2001 From: Anton Hvornum Date: Wed, 17 Feb 2021 12:24:56 +0100 Subject: Implemented #106 in branch skip-partitioning. Also moving the disk_password from being a local variable to a BlockDevice setting/variable. --- examples/guided.py | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'examples') diff --git a/examples/guided.py b/examples/guided.py index 0efc438c..84676284 100644 --- a/examples/guided.py +++ b/examples/guided.py @@ -152,16 +152,11 @@ if archinstall.arguments['harddrive'].has_partitions(): else: archinstall.arguments['harddrive'].keep_partitions = False -exit(0) -while (disk_password := getpass.getpass(prompt='Enter disk encryption password (leave blank for no encryption): ')): - disk_password_verification = getpass.getpass(prompt='And one more time for verification: ') - if disk_password != disk_password_verification: - archinstall.log(' * Passwords did not match * ', bg='black', fg='red') - continue - archinstall.storage['_guided']['disk_encryption'] = True - break +disk_password = archinstall.get_password(prompt='Enter disk encryption password (leave blank for no encryption): ') +archinstall.arguments['harddrive'].encryption_passwoed = disk_password +exit(0) # Ask for a hostname hostname = input('Desired hostname for the installation: ') if len(hostname) == 0: -- cgit v1.2.3-54-g00ecf