index : archinstall32 | |
Archlinux32 installer | gitolite user |
summaryrefslogtreecommitdiff |
author | Anton Hvornum <anton.feeds+github@gmail.com> | 2020-12-06 12:03:36 +0100 |
---|---|---|
committer | Anton Hvornum <anton.feeds+github@gmail.com> | 2020-12-06 12:03:36 +0100 |
commit | 1edb8f6f7224d7d715ce622266e9b5fdc8da3da2 (patch) | |
tree | fdf032af9e91f2008d0d876aab3af69e55a9870a /archinstall/lib | |
parent | b6c6e414b1a46fed7f118e7c441cb29ba26b5dc8 (diff) |
-rw-r--r-- | archinstall/lib/profiles.py | 8 |
diff --git a/archinstall/lib/profiles.py b/archinstall/lib/profiles.py index cf5bca91..c2aa2aa2 100644 --- a/archinstall/lib/profiles.py +++ b/archinstall/lib/profiles.py @@ -15,7 +15,7 @@ def grab_url_data(path): response = urllib.request.urlopen(safe_path, context=ssl_context) return response.read() -def list_profiles(filter_irrelevant_macs=True, sub_path=''): +def list_profiles(filter_irrelevant_macs=True, subpath=''): # TODO: Grab from github page as well, not just local static files if filter_irrelevant_macs: local_macs = list_interfaces() @@ -23,7 +23,7 @@ def list_profiles(filter_irrelevant_macs=True, sub_path=''): cache = {} # Grab all local profiles found in PROFILE_PATH for PATH_ITEM in storage['PROFILE_PATH']: - for root, folders, files in os.walk(os.path.abspath(os.path.expanduser(PATH_ITEM+sub_path))): + for root, folders, files in os.walk(os.path.abspath(os.path.expanduser(PATH_ITEM+subpath))): for file in files: if os.path.splitext(file)[1] == '.py': tailored = False @@ -43,7 +43,7 @@ def list_profiles(filter_irrelevant_macs=True, sub_path=''): # Grab profiles from upstream URL if storage['PROFILE_DB']: - profiles_url = os.path.join(storage["UPSTREAM_URL"]+sub_path, storage['PROFILE_DB']) + profiles_url = os.path.join(storage["UPSTREAM_URL"]+subpath, storage['PROFILE_DB']) try: profile_list = json.loads(grab_url_data(profiles_url)) except urllib.error.HTTPError as err: @@ -61,7 +61,7 @@ def list_profiles(filter_irrelevant_macs=True, sub_path=''): continue tailored = True - cache[profile[:-3]] = {'path' : os.path.join(storage["UPSTREAM_URL"]+sub_path, profile), 'description' : profile_list[profile], 'tailored' : tailored} + cache[profile[:-3]] = {'path' : os.path.join(storage["UPSTREAM_URL"]+subpath, profile), 'description' : profile_list[profile], 'tailored' : tailored} return cache |