
如果git remote add origin時提示說在遠程倉庫有origin了,可以選擇git remote rm origin或者換個其他任意的字符串。
分支創建:
在本地新建一個分支: git branch Branch1
切換到你的新分支: git checkout Branch1
將新分支發布在gitlab上: git push origin Branch1
在本地刪除一個分支: git branch -d Branch1
在github遠程端刪除一個分支: git push origin :Branch1 (分支名前的冒號代表刪除)
創建tag
本地某個分支創建一個tag:git tag v0.0.1 -m "dev v0.0.1版本"
發布到gitlab:git push origin v0.0.1
刪除tag
刪除本地tag:git tag -d v0.0.1
刪除遠程tag:git push origin --delete tag v0.0.1
進入.ssh文件夾,然后更改ssh gitlab 認證密碼 ssh-keygen -f id_rsa -p
