标签:echo centos7 Fix div wget file etc 更新 centos
//
#!/bin/bash # Your Answer # filename: gitrefresh.sh # chmod u+x gitrefresh.sh # ./gitrefresh.sh sudo yum remove git -y rm -rf /usr/local/git mkdir /usr/local/git cd /usr/local/git # 安装依赖库 yum install curl-devel expat-devel gettext-devel openssl-devel zlib-devel -y yum install gcc perl-ExtUtils-MakeMaker -y wget https://www.kernel.org/pub/software/scm/git/git-2.9.5.tar.gz # cp /home/git-2.9.5.tar.gz /usr/local/git tar -zxvf git-2.9.5.tar.gz cd git-2.9.5 ./configure --prefix=/usr/local/git make && make install echo ‘export PATH=/usr/local/git/bin:$PATH‘ >> /etc/profile # 生效环境变量 source /etc/profile git --version
//
标签:echo centos7 Fix div wget file etc 更新 centos
原文地址:https://www.cnblogs.com/RYSBlog/p/14147814.html