Python – How upgrade version pip by proxy

PROXYpython

for my task need install pywin32 pack.
Python can install new pack only by proxy.

pip --proxy http://<username>:<password>@<hostname>:<port> install pywin32

But installing end error

Collecting pywin32
  Could not find a version that satisfies the requirement pywin32 (from versions
: )
No matching distribution found for pywin32
You are using pip version 8.1.2, however version 9.0.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' comm
and.

How upgrade version pip by proxy?

p.s. try to use

pip --proxy http://<username>:<password>@<hostname>:<port> -m pip install --upgrade pip

But result

Unknown option: --
usage: python [option] ... [-c cmd | -m mod | file | -] [arg] ...
Try `python -h' for more information.

Best Answer

pip is equivalent to python -m pip, so you can try

pip --proxy http://<username>:<password>@<hostname>:<port> install --upgrade pip

or

python -m pip --proxy http://<username>:<password>@<hostname>:<port> install --upgrade pip
Related Topic