git 服务器搭建

git 服务器搭建

1、下载git服务器(源码安装) https://github.com/git/git/releases
2、解压 tar -zxvf v2.16.0.tar.gz
3、cd git-2.16.0
4、make prefix=/usr/local/git all
5、make prefix=/usr/local/git install
6、配置环境变量
vi /etc/profile
export PATH="/usr/local/git/bin:$PATH" #添加这一条到最后一行
然后保存退出 :wq
使之生效: source /etc/profile

原文地址:https://www.cnblogs.com/soabstract/p/8432241.html