git 常用实例
Clone and Checkout
-
clone远程仓库
-
匿名clone
-
git 协议克隆
git clone git@github.com:TonyNie/multiplication.git
-
https协议克隆
git clone https://tony_nie@bitbucket.org/tony_nie/open-stunclient.git
-
-
删除远程分支
git push origin --delete branchname
Tag
-
创建轻量级TAG
git tag v-0.1
-
创建有附注的标签
git tag -a v3.8rc -m "RC 3.8"
-
创建带签名的标签
git tag -s v3.8rc -m "RC 3.8"
-
将标签v3.8rc推送到远程仓库orgin
git push origin v3.8rc
-
将本地所有的标签都推送到远程仓库origin
git push origin --tags
-
将标签v3.8rc 检出
git checkcout -b NEWBRANCH v3.8rc
-
删除本地标签v0.1
git tag -d v0.1
-
删除远程仓库上的标签k1.2.0
git push origin --delete tag k1.2.0