![](https://img-blog.csdnimg.cn/20201014180756922.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
GIT
JIANJIANJIAN1111
喜欢电子的人
展开
-
git 拉分支代码
git拉取代码到本地把代码获取到某个文件夹,在文件夹右键选择Git Bash Here第一步:git config --global user.name "git权限的名称"第二步:$ git config --global user.email "git的帐号"第三步:$git clone -b develop XXX需要获取的代码 如:http://git.ui-tech.cn/asset/data-transfer这是获取某个分支的代码提交本地代码到远程服...原创 2020-11-04 16:23:28 · 291 阅读 · 1 评论 -
Received disconnect from xxx.xxx.xxx port 22:2: Too many authentication failures for git
1.分析尝试各种办法,尝试过去修改/etc/ssh/sshd_config 文件里把MaxAuthTries 10取消注释,也不管用,把原来值改大也不管用。好不烦恼,这个耽误一个小时。2.解决索性直接把ssh的公共密钥重新在gitlab客户端删除掉,重新加一下。复制本地公共密钥路径在.ssh/id_rsa.pub里面,粘贴到下图得到Key中,点击Add key按钮。就ok啦。...原创 2020-11-02 17:45:54 · 3815 阅读 · 0 评论 -
换网络后git clone 就下载不了
1.问题用公司的网络git clonegit@xxx.xxx.xxx/xxx.git可以的,但是电脑换成别的网络后git clonegit@xxx.xxx.xxx/xxx.git 会出现ssh: connect to host gitlab.neolix.cn port 22: Connection refusedfatal: Could not read from remote repository.2.分析出现这个问题在网上查找啦半个小时,耽误大量时间,后来把ssh 网址换成http..原创 2020-10-25 20:28:35 · 380 阅读 · 0 评论 -
git 常用命令
1.拉取最新代码git clone --depth=1git@xxx.xxx.cn:xxx/xxxx.git2.拉取不同分支的代码git clone -b + 分支名 +网址git clone -b xavier_canTest2git@xxx.xxx.cn:xxx/xxxx.git原创 2020-10-16 17:30:49 · 124 阅读 · 0 评论 -
Linux 创建本地仓设置SSH公钥,创建分支,连接远程仓,提交代码流程
一.创建本地仓1.首先查看下git版本 没有的先下载gitroot@ubuntu:/home/code/test# git --versiongit version 2.25.1root@ubuntu:/home/code/test# ^Croot@ubuntu:/home/code/test# 2.在当前路径中输入git status 查看git本地仓是否建好root@ubuntu:/home/code# git statusfatal: not a git reposito原创 2020-10-13 17:42:47 · 401 阅读 · 0 评论 -
git
jiang@DESKTOP-H9PNI47 MINGW64 /d/File/Git/Vehicle_2_0 (lzj_vehicle_2.0)$ git stash listjiang@DESKTOP-H9PNI47 MINGW64 /d/File/Git/Vehicle_2_0 (lzj_vehicle_2.0)$ git stash --listerror: unknown option `list'usage: git stash [push [-p|--patch] [-k|--[n..原创 2020-10-09 20:03:08 · 229 阅读 · 0 评论 -
git 分支创建并上传 用bash工具
1.创建branchjiang@DESKTOP-H9PNI47 MINGW64 /d/File/Git/NewVehicle (master)$ git branch* masterjiang@DESKTOP-H9PNI47 MINGW64 /d/File/Git/NewVehicle (master)$ git branch -a* master remotes/origin/masterjiang@DESKTOP-H9PNI47 MINGW64 /d/File/Git/NewV原创 2020-09-28 11:03:48 · 239 阅读 · 0 评论 -
GIT 提交代码
步骤:jiang@DESKTOP-H9PNI47 MINGW64 /d/File/Git/NewVehicle (master)$ git pushEverything up-to-datejiang@DESKTOP-H9PNI47 MINGW64 /d/File/Git/NewVehicle (master)$ git remote -vorigin http://gitlab.neolix.cn/space/new_vehicle.git (fetch)origin http:/原创 2020-09-19 19:37:07 · 184 阅读 · 0 评论 -
git commit命令
问题:git add .git push origin master后出现Everything up-to-date,然后在gitlab后台也没有发现更新内容。分析:没有在git push origin master前面使用git commit,当使用git commit 时候会进入编辑文本中,会显示增加的内容,然后把需要增加的内容前面的屏蔽#去掉,然后按下Esc键,再shift+:,写入wq保存退出。然后再输入git push origin master 就可以啦。...原创 2020-06-01 21:23:22 · 211 阅读 · 0 评论 -
gitlab 上传工程老是失败
今日修改工程要上传到gitlab 以前经常用svn用的gitlab比较少,有些生疏,公司用的gitlab,给我分一个子账户让我上传工程,当时有点懵,就开始百度啦,按照百度的要求一步一步来.1.git init 跟新下本地仓库2.git remote add origingit@gitlab.neolix.cn:xxxxxxxxxxxxxxxx.git(表示把本地仓库与远程仓库链接起来...原创 2020-04-17 17:50:09 · 752 阅读 · 0 评论