From 0de302c47dfde75f8a4967c03f7757e3ad86ee39 Mon Sep 17 00:00:00 2001 From: Anton Hvornum Date: Mon, 7 Dec 2020 20:18:47 +0100 Subject: Updated fstab to better match the given input --- archinstall/lib/installer.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'archinstall/lib/installer.py') diff --git a/archinstall/lib/installer.py b/archinstall/lib/installer.py index 6d3be605..56cba9fb 100644 --- a/archinstall/lib/installer.py +++ b/archinstall/lib/installer.py @@ -118,9 +118,9 @@ class Installer(): def genfstab(self, flags='-pU'): self.log(f"Updating {self.mountpoint}/etc/fstab", level=LOG_LEVELS.Info) - o = b''.join(sys_command(f'/usr/bin/genfstab {flags} {self.mountpoint}')) - with open(f"{self.mountpoint}/etc/fstab", 'a') as fstab: - fstab.write(f"\n{o.decode('UTF-8')}") + with open(f"{self.mountpoint}/etc/fstab", 'ab') as fstab: + for line in sys_command(f'/usr/bin/genfstab {flags} {self.mountpoint}'): + fstab.write(f"{line}\n") if not os.path.isfile(f'{self.mountpoint}/etc/fstab'): raise RequirementError(f'Could not generate fstab, strapping in packages most likely failed (disk out of space?)\n{o}') -- cgit v1.2.3-54-g00ecf