问题
I ran:
python -m pip --version
And it returned:
pip 8.1.2 from C:\Users\myonl\AppData\Local\Programs\Python\Python35-32\lib\site-packages (python 3.5)
So I set my path to the above, but when I try to actually use pip I get:
pip install PyQt4
'pip' is not recognised as an internal or external command, operable program or batch file.
What am I doing wrong?
回答1:
The first time you do python -m pip
, the second time you do pip
.
pip
is not on your PATH, but python
is. You can fix that, or you can call it using python -m pip
.
Also possible is that you simply need to refresh your console window so it picks up the change you've made to PATH. Try closing your terminal and re-opening it and seeing if you have the same problem.
来源:https://stackoverflow.com/questions/54172872/how-to-set-pip-environment-path