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

配置GitLab或Git环境之教程

时间:2019-01-30 07:15:18      阅读:179      评论:0      收藏:0      [点我收藏+]

标签:title   git bash   钻石   ast   als   tar   生成   use   name   

1、安装好Git后,首先打开开始菜单的所有程序里面的git文件夹,打开Git Bash/

技术分享图片技术分享图片?

2、弹出的命令行里面输入ssh-keygen 输入y,一直Enter

技术分享图片技术分享图片?

3、在输入:cat  ~/.ssh/id_rsa.pub 确认,会生成一段代码。复制代码。

技术分享图片技术分享图片?

4、打开gitlab网页,打开右上角文件设置菜单,找到SSH Keys,将代码复制到key文本框中,点击Add key(两次)

.

5、点击Profile中,复制Name,然后在命令行中输入git config --global user.name "Jordan"

技术分享图片技术分享图片?

技术分享图片技术分享图片?

 

 

6、回到Profile中,复制Email,然后在命令行中输入git config --global user.email "xxxxxx@xx.com"

技术分享图片技术分享图片?

7、点击钻石回到首页,打开Test/testcase,将HTTP改为SSH,复制到剪切板,

技术分享图片技术分享图片?

技术分享图片技术分享图片?

8、打开开始菜单的所有程序里面的git文件夹,打开Git GUI,点击cloneExisting Repostory,命名后进入Clone Existing Repostory 界面,复制SSH地址到SourceLocation中,选择目标目录(你常用的目录)确定返回Clone Existing Repostory 界面,在Target Directory中目录后新建一个testcase文件夹(不要在选择目标时新建,否则会显示已存在目录)

 

技术分享图片技术分享图片?

技术分享图片技术分享图片?

配置GitLab或Git环境之教程

标签:title   git bash   钻石   ast   als   tar   生成   use   name   

原文地址:https://www.cnblogs.com/johnsonbug/p/10336525.html

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