码迷,mamicode.com
首页 > 其他好文 > 详细

centos 7 安装 Git-2.23.0

时间:2019-10-14 23:45:53      阅读:534      评论:0      收藏:0      [点我收藏+]

标签:cvs   port   多个   ast   wget   nmp   rap   force   soc   

Git是一个免费的开源 分布式版本控制系统,旨在快速高效地处理从小型到大型项目的所有内容。

Git 易于学习,占地面积小,具有闪电般的快速性能。

它具有诸如Subversion,CVS,Perforce和ClearCase之类的SCM工具,并且具有廉价的本地分支,方便的暂存区域和 多个工作流等功能。

 

Git官方网站:https://git-scm.com/

Linux/Unix 源代码地址:https://mirrors.edge.kernel.org/pub/software/scm/git/

稳定版 | git-2.23.0.tar.gz | https://mirrors.edge.kernel.org/pub/software/scm/git/git-2.23.0.tar.gz

 

1.下载源代码到目录 /usr/local/src/

[root@localhost ~]# wget https://mirrors.edge.kernel.org/pub/software/scm/git/git-2.23.0.tar.gz -nc -c -P /usr/local/src/

2.安装依赖包 {包含更多格式的文档(如 doc, html, info)}

yum install -y --exclude=kernel*,centos-release*,httpd,nginx,php,mysql,mairadb,python-psutil,python2-psutil,cacti,git,svn yum-fastestmirror redhat-lsb compat* logrotate lsof net-tools lrzsz cmake wget gcc gcc-c++ make zlib-devel readline-devel automake ncurses-devel epel-release bash-completion sysstat mlocate kernel kernel-headers kernel-devel iptables-services apr* autoconf bison bzip2 bzip2* bzip2-devel cpp curl curl-devel fontconfig fontconfig-devel freetype* freetype-devel gd gettext gettext-libs gettext-devel gettext-common-devel glibc glibc-devel glibc-headers keyutils keyutils-libs-devel krb5-devel libcom_err-devel libpng-devel libjpeg* libsepol-devel libselinux-devel libstdc++-devel libtool libtool* libgomp libxml2 libxml2-devel libXpm* libxml* libXaw-devel libXmu-devel libtiff libtiff* mpfr ncurses* ntp ntpdate* openssl-devel patch pcre-devel php-common php-gd policycoreutils telnet t1lib t1lib* nasm nasm* libwebp libwebp-devel libjpeg-devel db4-devel libXpm-devel libc-client-devel openldap-devel mysql-devel libicu-devel libcurl libcurl-devel libzip cpan tcp_wrappers psmisc tree cyrus-sasl-md5 vim chrony rsync xinetd crontabs iptables-utils git dos2unix boost-devel boost-doc libxslt libxslt-devel libdb4* qpid* gnutls boost-system avahi-libs boost-thread dwz dyninst emacs-filesystem fipscheck fipscheck-lib gdb libdwarf libedit libgfortran unzip zip trousers pakchois nettle neon m4 mokutil libproxy libstdc++-devel libquadmath libquadmath-devel libmpc libmodman libgnome-keyring subversion-libs systemtap-devel systemtap-runtime openssh openssh-clients systemtap-client perl perl-Carp perl-Data-Dumper perl-Encode perl-Error perl-Exporter perl-File-Path perl-File-Temp perl-Filter perl-Getopt-Long perl-Git perl-HTTP-Tiny perl-PathTools perl-Pod-Escapes perl-Pod-Perldoc perl-Pod-Simple perl-Pod-Usage perl-Scalar-List-Utils perl-Socket perl-Storable perl-TermReadKey perl-Test-Harness perl-Text-ParseWords perl-Thread-Queue perl-Time-HiRes perl-Time-Local perl-XML-Parser perl-constant perl-libs perl-macros perl-parent perl-podlators perl-srpm-macros perl-threads perl-threads-shared screen tcpdump nc mtr nmap tcl policycoreutils-python policycoreutils-python.x86_64 httpd libjpeg gd php-mysql php-mbstring php-process  php-snmp php-ldap php-xml net-snmp net-snmp-utils rrdtool rrdtool-devel rrdtool-php help2man net-snmp-devel binutils libffi-devel libtasn1-devel p11-kit-devel dh-autoreconf expat-devel perl-devel asciidoc xmlto docbook2X --skip-broken && yum clean all && sudo ln -s /usr/bin/db2x_docbook2texi /usr/bin/docbook2x-texi

3.解压源代码编译并安装

[root@localhost git-2.23.0]# cd
[root@localhost ~]# cd /usr/local/src/
[root@localhost src]# tar -zxvf git-2.23.0.tar.gz
[root@localhost src]# cd git-2.23.0
[root@localhost git-2.23.0]# mkdir -p /usr/local/git
[root@localhost git-2.23.0]# ./configure --prefix=/usr/local/git --with-gitconfig=/etc/gitconfig && make && make install
[root@localhost git-2.23.0]# make man && make install-man
[root@localhost git-2.23.0]# make html && make htmldir=/usr/share/doc/git-2.23.0 install-html
[root@localhost git-2.23.0]# git --version
git version 2.23.0
Git-2.23.0-64 windows客户端下载:https://github.com/git-for-windows/git/releases/download/v2.23.0.windows.1/Git-2.23.0-64-bit.exe
https://gitforwindows.org/
https://tortoisegit.org/download/
2.8.0.0-64 windows客户端中文包4M下载:https://download.tortoisegit.org/tgit/2.8.0.0/TortoiseGit-LanguagePack-2.8.0.0-64bit-zh_CN.msi
2.8.0.0-64 windows客户端安装包19M下载:https://download.tortoisegit.org/tgit/2.8.0.0/TortoiseGit-2.8.0.0-64bit.msi
创建 Git 仓库指定kings-dev_repo目录
[root@localhost local]# mkdir -p /data/git2.23
[root@localhost local]# cd /data/git2.23/
Initialized empty Git repository in /data/git2.23/.git/
[root@localhost git2.23]# git init kings-dev_repo
Initialized empty Git repository in /data/git2.23/kings-dev_repo/.git/

配置Git
[root@localhost git2.23]# git config --global user.name "Kings-dev"
[root@localhost git2.23]# git config --global user.email huixst@163.com
[root@localhost git2.23]# git config --global core.editor emacs
[root@localhost git2.23]# git config --list
user.name=Kings-dev
user.email=huixst@163.com
core.editor=emacs
core.repositoryformatversion=0
core.filemode=true
core.bare=false
core.logallrefupdates=true
[root@localhost git2.23]# git config user.name
Kings-dev
创建用户授权仓库 [root@localhost git2.
23]# useradd wwweee000 [root@localhost git2.23]# passwd wwweee000 Changing password for user wwweee000. New password: BAD PASSWORD: The password is a palindrome Retype new password: passwd: all authentication tokens updated successfully. [root@localhost git2.23]# chown -R wwweee000:wwweee000 kings-dev_repo/.git/

 

技术图片

 

 

 技术图片

 

技术图片

 技术图片

 

技术图片

 

 

 技术图片

 

技术图片

 

 

 技术图片

 

 

 技术图片

 

 

 

 

 技术图片

 

技术图片

 

 

 

 技术图片

 

 

 技术图片

技术图片

 

centos 7 安装 Git-2.23.0

标签:cvs   port   多个   ast   wget   nmp   rap   force   soc   

原文地址:https://www.cnblogs.com/huixst/p/11672214.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!