自建git服务器连接Pycharm系列一:使用centos7自带git1.8

在自己的Linux虚拟机上,搭建git服务器,用来保存代码。
这里是先简单熟悉一下。后期的代码管理,并不用自带的git。

在centos7中,默认自带git

查看git版本
[root@dscrapy01 ~]# git --version
git version 1.8.3.1

找一个github上的项目做测试。

这个是fork的别人的项目。

  • 当克隆的时候,提示一个错误:
[root@dscrapy01 ~]# git clone https://github.com/feature09/clusterdock
正克隆到 'asteroids'...
fatal: unable to access https://github.com/feature09/clusterdock/': Peer reports incompatible or unsupported protocol version.
  • 百度查看的解决方案:
更新了nss/curl/libcurl这三部分内容
[root@dscrapy01 ~]# yum update -y nss curl libcurl

重新克隆项目,成功。

[root@dscrapy01 ~]# git clone https://github.com/feature09/clusterdock
正克隆到 'clusterdock'...
remote: Counting objects: 157, done.
remote: Total 157 (delta 0), reused 0 (delta 0), pack-reused 157
接收对象中: 100% (157/157), 124.99 KiB | 2.00 KiB/s, done.
处理 delta 中: 100% (67/67), done.

进入到项目目录,项目目录就在当前用户家目录下

[root@dscrapy01 clusterdock]# pwd
/root/clusterdock

猜你喜欢

转载自blog.51cto.com/feature09/2159936
今日推荐