update
parent
ed8e4c7720
commit
b5c19ec206
|
@ -0,0 +1,61 @@
|
|||
git局域网访问:http://192.168.1.138:2700/
|
||||
外部访问:http://39.82.85.250:2700/
|
||||
|
||||
git下载地址
|
||||
http://git-scm.com/downloads
|
||||
|
||||
https://www.cnblogs.com/goloving/p/14782692.html
|
||||
https://blog.csdn.net/jsklnice/article/details/121471232
|
||||
克隆:git clone http://xxxx/xxxx.git
|
||||
<1>git push未经授权
|
||||
解决方法:重置git的认证设置
|
||||
|
||||
git config --system --unset credential.helper
|
||||
然后在git push的时候重新输入git的账号和密码即可
|
||||
|
||||
备注:每次操作都输入账号密码比较麻烦,输入下面命令保存账号密码(第2次生效)
|
||||
|
||||
git config credential.helper 'cache --timeout=3600'
|
||||
|
||||
git每次都要输入密码,记住密码方法
|
||||
https://blog.csdn.net/weixin_43795761/article/details/125011382
|
||||
1、首先,在Git.bash文件中输入命令:
|
||||
git config --global credential.helper store
|
||||
2、然后你会发现你的C:\Users\用户名xx.gitconfig**文件会多出以下代码:
|
||||
[credential]
|
||||
helper = store**
|
||||
3、紧接着,使用git pull或者git push 命令,根据提示输入帐号和密码。这时你的本地生成一个类似C:\Users\用户名xx.git-credentials文件,用于记录帐号密码。
|
||||
完成以上几步,下次就不用再次输帐号密码了。
|
||||
|
||||
登录用户账号
|
||||
git config --global user.name "蒋修裕"
|
||||
git config --global user.email "422334010@qq.com"
|
||||
git remote add origin https://gitee.com/jiang-xiuyu/wem-iii.git
|
||||
|
||||
<2>文件上传
|
||||
git status -s
|
||||
git commit -m "添加到远程"
|
||||
git push origin master
|
||||
<3>文件夹上传(含文件)
|
||||
1.cd 文件夹
|
||||
2.git add .”(注意“. ”不要省略)
|
||||
3.git commit -m "备注"
|
||||
4.git push -u origin master
|
||||
|
||||
<4>删除远程仓库文件
|
||||
git pull origin master
|
||||
git rm --cached 文件名/git rm -r --cached 文件夹名
|
||||
git commit -m update
|
||||
git push -u origin master //提交到仓库
|
||||
<5>如何建立分支
|
||||
https://blog.csdn.net/qq_37899792/article/details/121328761
|
||||
<6>如何删除分支
|
||||
本地:git branch -d (branchname)
|
||||
线上:git push origin --delete (branchname)
|
||||
|
||||
http://192.168.1.138:2700/JiangXiuyu/demo.git
|
||||
http://192.168.1.138:2700/JiangXiuyu/demo.git
|
||||
<7如何克隆分支>
|
||||
git checkout -t origin/<分支名称>
|
||||
|
||||
|
Loading…
Reference in New Issue