For some Maya distribute in some OS platform, pip might already be available.
You can simply do this to test:
/path/to/maya/../mayapy -m pip --version
If this did print out the version correctly, it means pip is all good.
Now to install a python package like iutest you just simply do:
/path/to/maya/../mayapy -m pip install iutest
End of story.
If pip is not available yet for your mayapy:
- Download the get-pip.py , put it in the root of Maya's python "site-packages" folder.
- To know where is the "site-packages" folder, just do:
/path/to/maya/../mayapy -m site
It will print out a list of sites, the one inside Maya installation directory and ends with "site-packages" is the directory you want to put the get-pip.py to.
-
With get-pip module ready, we run it to install pip:
/path/to/maya/../mayapy -m get-pip
-
Now pip is ready. You can try the trick at the start to check pip and install packages.