Git基本环境配置
yum源中已有的git版太低,所以选择源码编译,也比较简单,由于git上许多项目需要python环境不同,因此保留系统自带的python2.x版本,并编译python3.x
# wget https://www.python.org/ftp/python/3.5.2/Python-3.5.2.tgz # tar xvf Python-3.5.2.tgz -C /usr/local/src # cd /usr/local/src/Python-3.5.2 # ./configure --prefix=/usr/local/python3 # make && make install # ln -sv /usr/local/python3/bin/python3.5 /usr/local/bin/python3
python编译报错 urllib.error.URLError: <urlopen error unknown url type: https> <br>
安装openssl,openssl-devel后取消如下关于SSL的注释,在重新编译
vim Python-path/Modules/Setup.dist 207 #SSL=/usr/local/sslSL)/include -I$(SSL)/include/openssl \ 208 #_ssl _ssl.c \ib -lssl -lcrypto 209 # -DUSE_SSL -I$(SSL)/include -I$(SSL)/include/openssl \ 210 # -L$(SSL)/lib -lssl -lcryptoefault because it breaks builds
安装setuptools&&pip
https://pypi.python.org/pypi/setuptools
http://peak.telecommunity.com/DevCenter/EasyInstall
# python --version Python 2.7.5 # wget https://bootstrap.pypa.io/ez_setup.py -O - | python ##系统自带python2.x # wget https://pypi.python.org/packages/e7/a8/7556133689add 8d1a54c0b14aeff0acb03c64707ce100ecd53934da1aa13/pip8.1.2.tar.gz#md5=87083c0b9867963b29f7aba3613e8f4a ##安装pip # tar xvf pip-8.1.2.tar.gz -C /usr/local/ # cd /usr/local/pip-8.1.2/ # python setup.py install # pip --version pip 8.1.2 from /usr/lib/python2.7/site-packages/pip-8.1.2-py2.7.egg (python 2.7) # python3 -V Python 3.5.2 # wget https://bootstrap.pypa.io/ez_setup.py -O - | python3 自定义python # cd /usr/local/pip-8.1.2/ # python3 setup.py install # pip3 -V pip 8.1.2 from /usr/local/python3/lib/python3.5/site-packages/pip-8.1.2-py3.5.egg (python 3.5)
安装git
# yum install curl-devel expat-devel gettext-devel openssl-devel zlib-devel asciidoc xmlto docbook2x # tar xvf git-2.9.2.tar.gz -C /usr/local/src/ # cd /usr/local/src/git-2.9.2/ # make configure # ./configure --prefix=/usr/local # make && make install
GitHub 教程系列文章:
GitHub 的详细介绍:请点这里
GitHub 的下载地址:请点这里
相关推荐
huavhuahua 2020-11-20
weiiron 2020-11-16
cakecc00 2020-11-15
千锋 2020-11-15
JakobHu 2020-11-14
guangcheng 2020-11-13
xirongxudlut 2020-11-10
solarLan 2020-11-09
pythonxuexi 2020-11-08
文山羊 2020-11-07
susmote 2020-11-07
wuShiJingZuo 2020-11-05
Pythonjeff远 2020-11-06
jacktangj 2020-11-04
lousir 2020-11-04
Noneyes 2020-11-10
ailxxiaoli 2020-11-16
chensen 2020-11-14
Nostalgiachild 2020-11-13