平台:win10
python 3.6问题描述:在windows上执行git-review但是提示没有该命令
tips:要先安装python和pip
Windows[edit]
Python is needed for git-review to function and pip is used for its installation:
- Install python or upgrade to the most current version of Python 2 or Python 3.
- Important: Do not install Python in any directory with a space in its path as there is a pip bug (see , use the default, e.g.
C:\Python34\
- During the Python installation, manually select Add python.exe to Path
- Otherwise, add your python scripts directory manually to the system path (Settings, Control panel, System, Advanced system settings, Environment variables, User variables, Path; e.g.
C:\Python34\;C:\Python34\Scripts\;
). Different directories in path are delimited by a semicolon ";" only - do not add any whitespace to path list.) - Python 3.4 has pip already installed. Only if you have an older version, install pip by following the instructions here.
- Run Git Bash as Administrator (right click on icon for this option) and install git-review with the following command:
-
$ pip install git-review
- If you experience problems such as these:
-
Retrying (Retry(total=4, connect=None, read=None, redirect=None)) after connection broken by 'ConnectTimeoutError(<pip._vendor.requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x03B55750>, 'Connection to pypi.python.org timed out. (connect timeout=15)')': /simple/git-review/
- try running:
-
$ pip install git-review --proxy=www-proxy-lon.uk.oracle.com:80
- the exact proxy to use can be extracted from http://wpad/wpad.dat file.
- To use
git review
, you have to be in a git clone directory that already contains a (possibly hidden).gitreview
configuration file (see Gerrit/Advanced usage#Setting up a repository for git-remote), otherwise you will get the error message UnboundLocalError: local variable 'no_git_dir' referenced before assignment