pymel.mayautils.getMayaLocation

getMayaLocation(version=None)

Get the location of Maya (defined as the directory above /bin)

Uses the $MAYA_LOCATION environment variable and sys.executable path.

If version is passed, will attempt to find a matching Maya location. If the version found by the methods above does not match the requested version, this function uses a simple find/replace heuristic to modify the path and test if the desired version exists. If no matching version is found, returns None

Remember to pass the FULL version (with extension if any) to this function!

Previous topic

pymel.mayautils.getMayaAppDir

Next topic

pymel.mayautils.getUserPrefsDir

Core

Core Modules

Other Modules

This Page