Home  >  Article  >  System Tutorial  >  Install Git server on Centos7 using yum

Install Git server on Centos7 using yum

WBOY
WBOYforward
2023-12-28 17:04:39563browse

Install git

yum install git

Check git version

git –version

Found that it is not a newer version or the version we want

Remove this version git

yum remove git

Download the compilation tool

yum -y groupinstall Development Tools

Download dependency package

##yum -y install zlib-devel perl-ExtUtils-MakeMaker asciidoc xmlto openssl- devel

Download the source code of the latest version of Git

wget https://www.kernel.org/pub/software/scm/git/git-2.32.0 .tar.gz

Log in to https://github.com/git/git/releases to view the latest version of git. Do not download with -rc as it represents a release candidate.

https://github.com/git/git/archive/refs/tags/v2.32.0.tar.gz

Unzip

tar -zxvf git-2.9.5.tar.gz

Enter directory configuration

cd git-2.32.0

./configure –prefix=/usr/local/ git

Install

make && make install

Configure global path

export PATH="/ usr/local/git/bin:$PATH"

source /etc/profile

The above is the detailed content of Install Git server on Centos7 using yum. For more information, please follow other related articles on the PHP Chinese website!

Statement:
This article is reproduced at:jb51.net. If there is any infringement, please contact admin@php.cn delete