mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 12:54:40 +01:00
simplified repository resolving using OpenPypeVersion.get_installed_version
This commit is contained in:
parent
a003bceb16
commit
9fd2a7b978
1 changed files with 3 additions and 7 deletions
|
|
@ -732,13 +732,9 @@ class BootstrapRepos:
|
|||
if repo_dir:
|
||||
version = self.get_version(repo_dir)
|
||||
else:
|
||||
version = OpenPypeVersion.get_installed_version_str()
|
||||
# QUESTION Can we use 'OPENPYPE_ROOT' env variable or it may
|
||||
# not be defined yet?
|
||||
if getattr(sys, "frozen", False):
|
||||
repo_dir = Path(sys.executable).parent
|
||||
else:
|
||||
repo_dir = Path(Path(__file__).parent / "..")
|
||||
installed_version = OpenPypeVersion.get_installed_version()
|
||||
version = str(installed_version)
|
||||
repo_dir = installed_version.path
|
||||
|
||||
if not version:
|
||||
self._print("OpenPype not found.", LOG_ERROR)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue