From 20ba0b145cdccf5bf98879ca9e1a6811ef078519 Mon Sep 17 00:00:00 2001 From: Lord Anton Hvornum Date: Sat, 7 Apr 2018 10:48:23 +0200 Subject: Forgot to execute post-install inside arch-chroot --- archinstall.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/archinstall.py b/archinstall.py index f078445f..5970b385 100644 --- a/archinstall.py +++ b/archinstall.py @@ -214,7 +214,7 @@ if __name__ == '__main__': #TODO: This doesn't work either: (why the hell not?) # echo "newpass" | passwd --stdin root ? #o = run("arch-chroot /mnt echo 'root:{pin}' | chpasswd".format(**args, pin=PIN)) - o = run('arch-chroot /mnt echo "{pin}" | passwd --stdin root'.format(**args, pin=PIN)) + o = run('arch-chroot /mnt \'echo "{pin}" | passwd --stdin root\''.format(**args, pin=PIN)) if 'user' in args: o = run('arch-chroot /mnt useradd -m -G wheel {user}'.format(**args)) o = run("arch-chroot /mnt echo '{user}:{pin}' | chpasswd".format(**args, pin=PIN)) @@ -258,9 +258,10 @@ if __name__ == '__main__': for title in instructions: print('[N] {}'.format(title)) for command in instructions[title]: - o = run(command) # arch-chroot /mnt ... - #if instructions[title][command]: - print(o) + o = run('arch-chroot /mnt {c}'.format(c=command)) + if instructions[title][command] and not instructions[title][command] in o: + print('[W] Post install command failed: {}'.format(o.decode('UTF-8'))) + #print(o) #o = run('umount -R /mnt') #if args['post'] == 'reboot': -- cgit v1.2.3-70-g09d2