changed_the_way_env_path_is_created

This commit is contained in:
mariusandreifilip 2019-05-30 16:49:17 +03:00 коммит произвёл mwobensmith
Родитель 17f41bf17c
Коммит 6cf9559e42
1 изменённых файлов: 7 добавлений и 2 удалений

Просмотреть файл

@ -218,6 +218,10 @@ class PathManager:
repo_details['iris_branch_head'] = repo.head.object.hexsha
return repo_details
@staticmethod
def get_win_environment_path():
return str(os.environ['USERPROFILE']) + '\\scoop\\shims\\firefox.exe'
@staticmethod
def get_local_firefox_path() -> str or None:
"""Checks if Firefox is installed on your machine."""
@ -230,12 +234,13 @@ class PathManager:
'C:\\Program Files (x86)\\Nightly\\firefox.exe',
'C:\\Program Files\\Mozilla Firefox\\firefox.exe',
'C:\\Program Files\\Firefox Developer Edition\\firefox.exe',
'C:\\Program Files\\Nightly\\firefox.exe',
str(os.environ['USERPROFILE']) + '\\scoop\\shims\\firefox.exe'],
'C:\\Program Files\\Nightly\\firefox.exe'],
'linux': ['/usr/bin/firefox',
'/usr/lib/firefox/firefox']
}
if OSHelper.is_windows():
paths['win'].append(PathManager.get_win_environment_path())
for path in paths[OSHelper.get_os().value]:
if os.path.exists(path):