PATH correction for /examples/
This commit is contained in:
parent
d00f0f0005
commit
df71d22498
|
|
@ -13,7 +13,7 @@ def run_as_a_module():
|
||||||
"""
|
"""
|
||||||
|
|
||||||
# Add another path for finding profiles, so that list_profiles() in Script() can find guided.py, unattended.py etc.
|
# Add another path for finding profiles, so that list_profiles() in Script() can find guided.py, unattended.py etc.
|
||||||
archinstall.storage['PROFILE_PATH'].append(os.path.abspath(f'{os.path.dirname(__file__)}/../examples'))
|
archinstall.storage['PROFILE_PATH'].append(os.path.abspath(f'{os.path.dirname(__file__)}/examples'))
|
||||||
|
|
||||||
if len(sys.argv) == 1:
|
if len(sys.argv) == 1:
|
||||||
sys.argv.append('guided')
|
sys.argv.append('guided')
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,6 @@ def list_profiles(filter_irrelevant_macs=True, subpath=''):
|
||||||
cache = {}
|
cache = {}
|
||||||
# Grab all local profiles found in PROFILE_PATH
|
# Grab all local profiles found in PROFILE_PATH
|
||||||
for PATH_ITEM in storage['PROFILE_PATH']:
|
for PATH_ITEM in storage['PROFILE_PATH']:
|
||||||
print('Walking:', PATH_ITEM)
|
|
||||||
for root, folders, files in os.walk(os.path.abspath(os.path.expanduser(PATH_ITEM+subpath))):
|
for root, folders, files in os.walk(os.path.abspath(os.path.expanduser(PATH_ITEM+subpath))):
|
||||||
for file in files:
|
for file in files:
|
||||||
if os.path.splitext(file)[1] == '.py':
|
if os.path.splitext(file)[1] == '.py':
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue