git 创建标签推送远程分支
git 创建标签推送远程分支
标签概念: tag, 对于迭代频繁的项目. 每一个标签可以理解为一个版本. 创建一个tag来指向软件开发中的一个关键时期,比如版本号更新的时候可以建一个v1.0、v1.1之类的标签.
tag的使用很简单, 包括
- 查看
- 创建
- 删除
查看tag
查看tag,列出所有tag,列出的tag是按字母排序的,和创建时间没关系
$ git tag
v1.1
v2.1
查看指定版本的tag
$ git tag -l 'v1.4.2.*'
v1.4.2.1
v1.4.2.2
v1.4.2.3
v1.4.2.4
查看tag信息
$ git show v1.1
tag v1.1
Tagger: maoyifei <maoyf@anchnet.com>
Date: Tue May 14 18:32:32 2019 +0800 coco 1.4.6 commit 29b7e04c1e18ca483787150ba9790688286f7fad (HEAD -> master, tag: v1.1, origin/master, origin/HEAD)
Author: maoyifei <maoyf@anchnet.com>
Date: Tue May 14 18:29:02 2019 +0800 ?docs:update README Description: 更新README OverView: ..
创建tag
创建轻量级tag 不会附带任何信息
git tag v1.1
创建带信息的tag
git tag -a v1.1 -m "This is first version."
给历史版本创建tag
- 查看历史版本id
$ git log --oneline
29b7e04 (HEAD -> master, tag: v1.1, origin/master, origin/HEAD) ?docs:update README
8a0a811 ?Fix: 添加coco模块
56ccd49 ?test: 删除coco
d412f3f ?refactor: 修复因版本更新导致"运维登录"需输入密码
0e2909a Update README.md
a2eefec update Instructions for use
5f281ca first time upload
- 选择 为
a2eefec版本创建标签
git tag -a v1.0 a2eefec -m "pre bate 1.0 "
创建一个基于指定tag的分支
git checkout -b test v1.1.2
推送标签到远程仓库
创建标签 都是先在本地创建标签, 现在需要将标签推送到远程仓库
将某个标签推送到远程仓库
git push origin master v1.0
将所有tag 一次全部push到仓库上
git push origin master --tags
删除tag
删除本地tag
git tag -d v1.0
删除远程仓库 tag
git push origin :refs/tags/v1.0
git 创建标签推送远程分支的更多相关文章
- git 本地库推送远程库 版本冲突的解决方法
参考: http://blog.csdn.net/shiren1118/article/details/7761203 github上的版本和本地版本冲突的解决方法 $ git push XXX ma ...
- git 远程分支创建与推送
git 远程分支创建与推送 原文地址:http://hi.baidu.com/lingzhixu/blog/item/4a9b830bb08a329fe850cd5b.html 本地分支的创建 本 ...
- git -分支管理(创建、推送、删除)
分支创建并推送: 1.查看当前所有分支,当前分支前面会标出一个*号 git branch -a 2.新建分支 git branch android_O 3.切换到新分支 git checkout an ...
- git 分支管理 推送本地分支到远程分支等
1.创建本地分支 local_branch git branch local_branch 2.创建本地分支local_branch 并切换到local_branch分支 git checkout - ...
- 如何把已有的本地git仓库,推送到远程新的仓库(github private)并进行远程开发;
最近因为疫情,在家干活,连接不上之前的gitlab 服务器:所以不得把现有的代码迁移到github 的私有仓库来进行开发:下面简要记录迁移的过程: 首先,确保你已经配置好本地访问远程私有仓库的所有权限 ...
- 推送代码分支时出现:fatal: 'origin' does not appear to be a git repository
关于ubuntu进行提交本地分支到远程库出现问题: 解决方案: 执行如下命令: git remote add origin git@github.com:yourusername/test.git y ...
- git 更改远程仓库地址,强行推送远程仓库
强行推送远程仓库 #把一个现有的工程拷贝一份 #去掉远程仓库关联 git remote rm origin #添加远程仓库关联 git remote add origin http://xxx.git ...
- git推送本地分支到远端 以及删除远端分支的 命令
git推送本地分支到远端 当前处于master分支,尝试用了git push origin warning: push.default is unset; its implicit value is ...
- Git撤回已经推送(push)至远程仓库提交(commit)的版本
背景 所以,经常会遇到已经提交远程仓库,但是又不是我想要的版本,要撤下来. 回退版本一般使用git reset,又分为: # 不删除工作空间改动代码,撤销commit,不撤销git add . git ...
随机推荐
- [React + GraphQL] Use useLazyQuery to manually execute a query with Apollo React Hooks
When using useQuery from Apollo React Hooks, the request will be sent automatically after the compon ...
- 在Vue中加入国际化(i18n)中英文功能
1.npm安装方法 npm install vue-i18n --save 2.在src资源文件下创建文件夹i18n,i18n下面创建index.js文件,引入VueI18n和导入语言包(按开发需求可 ...
- MongoDB 分片管理(一)检查集群状态
一.检查集群状态 1.1 使用sh.status()查看集群摘要信息 1.使用sh.status()可以查看分片信息.数据库信息.集合信息 sh.status() 如果数据块较多时,使用sh.stat ...
- SpringBoot监控中心
1.什么是SpringBoot监控中心? 2.为什么要使用SpringBoot监控中心?
- 使用webuploader实现大文件上传分片上传
本人在2010年时使用swfupload为核心进行文件的批量上传的解决方案.见文章:WEB版一次选择多个文件进行批量上传(swfupload)的解决方案. 本人在2013年时使用plupload为核心 ...
- Educational Codeforces Round 74
目录 Contest Info Solutions A. Prime Subtraction B. Kill 'Em All C. Standard Free2play D. AB-string E. ...
- 全栈开发工程师微信小程序-下
app.json { "pages": ["pages/index/index"] } index.wxml <text>Hello World&l ...
- 使用scala通过JNI技术调用c++代码
scala代码编写 Sample1.scala class Sample1 { // --- Native methods @native def intMethod(n: Int): Int def ...
- Python里面如何实现tuple和list的转换?
#list to tuple lis=[,,,,,] x=tuple(lis) print(type(x),x) #tuple to list tup=(,,,,,) y=list(tup) prin ...
- meshing-划分圆柱结构化网格
原视频下载地址:https://yunpan.cn/cqjeckrzEpVkY 访问密码 eb5d