We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 38e6099 commit 55e45daCopy full SHA for 55e45da
ansys/mapdl/core/launcher.py
@@ -387,7 +387,13 @@ def _get_available_base_ansys():
387
"""
388
base_path = None
389
if os.name == 'nt':
390
- base_path = os.path.join(os.environ['PROGRAMFILES'], 'ANSYS INC')
+ supported_versions = [194, 202, 211, 212]
391
+ awp_roots = {ver: os.environ.get(f'AWP_ROOT{ver}', '') for ver in supported_versions}
392
+ installed_versions = {ver: path for ver, path in awp_roots.items() if path and os.path.isdir(path)}
393
+ if installed_versions:
394
+ return installed_versions
395
+ else:
396
+ base_path = os.path.join(os.environ['PROGRAMFILES'], 'ANSYS INC')
397
elif os.name == 'posix':
398
for path in ['/usr/ansys_inc', '/ansys_inc']:
399
if os.path.isdir(path):
0 commit comments