index : archinstall32 | |
Archlinux32 installer | gitolite user |
summaryrefslogtreecommitdiff |
author | Anton Hvornum <anton.feeds+github@gmail.com> | 2020-11-01 23:01:41 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-11-01 23:01:41 +0000 |
commit | 57eef46f953574799e01b389e9f665f058bbd42d (patch) | |
tree | b0144e0a1d419326f421e7eed83937df25b4c873 | |
parent | 66e495e994a459188a567d1410ba29dc3b2282ac (diff) |
-rw-r--r-- | archinstall/__main__.py | 4 |
diff --git a/archinstall/__main__.py b/archinstall/__main__.py index fe4a3732..48d8a5ce 100644 --- a/archinstall/__main__.py +++ b/archinstall/__main__.py @@ -33,6 +33,10 @@ def run_as_a_module(): if f'{profile}.py' not in library: raise ProfileNotFound(f'Could not locate {profile}.py among the example files.') + # Swap the working dir, otherwise certain relative lookups won't work within archinstall. + # Mainly to avoid https://github.com/Torxed/archinstall/issues/59 + os.chdir(os.path.abspath(os.path.dirname(__file__))) + # Import and execute the chosen `<profile>.py`: spec = importlib.util.spec_from_file_location( library[f"{profile}.py"], |