Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/archinstall.py
diff options
context:
space:
mode:
authorAnton Hvornum <anton.feeds@gmail.com>2019-09-24 15:32:44 +0200
committerAnton Hvornum <anton.feeds@gmail.com>2019-09-24 15:32:44 +0200
commit14a91f5f7ccbe8cc3c157b58c805be9b9bae6c57 (patch)
tree286a39c9feab59e1b0c6cafccad56f7d2fd2f469 /archinstall.py
parentf973df9c39b6f9bb43abaaf6285a3c68b7a04ae8 (diff)
More fixes for #14 and also #9 has been resolved.
Diffstat (limited to 'archinstall.py')
-rw-r--r--archinstall.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/archinstall.py b/archinstall.py
index 3ea629db..1420c7b6 100644
--- a/archinstall.py
+++ b/archinstall.py
@@ -482,8 +482,8 @@ if __name__ == '__main__':
if not 'localtime' in args: args['localtime'] = 'Europe/Stockholm' if args['country'] == 'SE' else 'GMT+0' # TODO: Arbitrary for now
if not 'drive' in args:
drives = list(harddrives.keys())
- if len(drives) > 1 and not ('force' in args or 'first-drive' in args):
- raise KeyError("Multiple disks found, and --force / --first-drive wasn't specified.")
+ if len(drives) > 1 and not ('force' in args or 'first-drive' in args or 'default' in args):
+ raise KeyError("Multiple disks found, --drive=/dev/X not specified (or --force/--first-drive)")
args['drive'] = sorted(drives)[0] # First drive found
rerun = args['ignore-rerun']
@@ -585,6 +585,9 @@ if __name__ == '__main__':
# if not args['password']:
print(json.dumps(args, indent=4))
+ if args['default'] and not 'force' in args:
+ if(input('Are these settings OK? (No return beyond this point) N/y: ').lower() != 'y'):
+ die(1)
if not os.path.isfile(args['pwfile']):
#PIN = '0000'