From 0fed0b3ce544204ef3ef5ba155825e916f358323 Mon Sep 17 00:00:00 2001 From: Anton Hvornum Date: Fri, 5 Nov 2021 23:07:04 +0100 Subject: Fixed default zram conf location and imports --- archinstall/lib/installer.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/archinstall/lib/installer.py b/archinstall/lib/installer.py index 1d4297a0..b400e741 100644 --- a/archinstall/lib/installer.py +++ b/archinstall/lib/installer.py @@ -471,7 +471,7 @@ class Installer: # We could use the default example below, but maybe not the best idea: https://github.com/archlinux/archinstall/pull/678#issuecomment-962124813 # zram_example_location = '/usr/share/doc/zram-generator/zram-generator.conf.example' # shutil.copy2(f"{self.target}{zram_example_location}", f"{self.target}/usr/lib/systemd/zram-generator.conf") - with open(f"{self.target}/usr/lib/systemd/zram-generator.conf", "w") as zram_conf: + with open(f"{self.target}/etc/systemd/zram-generator.conf", "w") as zram_conf: zram_conf.write("[zram0]\n") if self.enable_service('systemd-zram-setup@zram0.service'): @@ -666,8 +666,6 @@ class Installer: # In accordance with https://github.com/archlinux/archinstall/issues/107#issuecomment-841701968 # Setting an empty keymap first, allows the subsequent call to set layout for both console and x11. - from .systemd import Boot - from .systemd import Boot with Boot(self) as session: session.SysCommand(["localectl", "set-keymap", '""']) @@ -691,8 +689,6 @@ class Installer: self.log(f"Invalid x11-keyboard language specified: {language}", fg="red", level=logging.ERROR) return False - from .systemd import Boot - from .systemd import Boot with Boot(self) as session: session.SysCommand(["localectl", "set-x11-keymap", '""']) -- cgit v1.2.3-70-g09d2