沙漠网

系统IT运维技术站

Centos编译安装最新GIT客户端

yum install zlib  zlib-devel perl-ExtUtils-Embed -y


到 https://www.kernel.org/pub/software/scm/git/ 下载最新的git源码包


解压源码包并编译安装

tar   xzvf   git-2.9.3.tar.gz

cd git-2.9.3

./configure
make
make install


建立软连接

ln -s /usr/local/bin/git   /usr/bin/git


查看版本

git --version


问:如何让git记住密码,避免每次pull代码都需要输入账户和密码?

答:操作如下:

cd /root

touch  .git-credentials

vim  .git-credentials

插入以下内容,username为账号,password为密码

https://username:password@github.com


执行:

git config --global credential.helper store


#如果修改记住的git账号,修改.git-credentials中的内容即可。

发表评论:

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。

«    2023年11月    »
12345
6789101112
13141516171819
20212223242526
27282930
控制面板
您好,欢迎到访网站!
  查看权限
网站分类
搜索
最新留言
文章归档
网站收藏
友情链接
  • RainbowSoft Studio Z-Blog
  • 订阅本站的 RSS 2.0 新闻聚合

Powered By Z-BlogPHP 1.7.3

Copyright Daixh.com Rights Reserved. 京ICP备09012299号-1

联系我:home#daixh.com (#改@)