mercurial - Hg - 查找 "cover"特定文件版本的标签

标签 mercurial tags

我们使用 hg 来控制大型项目的来源。每当我们发布一个版本时,我们都会在 hg 中标记版本。

现在说我进行了特定的修订(例如,我已经修复了一个错误)。我想知道哪些版本包含此修复程序,即哪些标签“覆盖”了此修订版。

我怎么找到这个?在 hg 标签中似乎只指标记的变更集。我记得在 ClearCase 中,标记修订的每个祖先也会被标记,有没有办法在 hg 中查看这些信息?

谢谢!

最佳答案

没有任何额外扩展的 Revsets 可以给你一些东西。喜欢
hg log -r "id(hash):tip and tag()"或更短更好(也许)的版本 hg log -r "descendants(hash) and tag()"
只是和我的 repo 中缩短的 revset 示例,并在修订后进行 merge

>hg glog -r "descendants(c9e3b41ec78f)"
@  changeset:   65:f202d72d6397
|  tag:         tip
|  parent:      63:c778bae76563
|  user:        Alex Bream
|  date:        Wed Nov 09 21:42:50 2011 +0600
|  summary:     2-9 яюыэюёЄ№■ фю 2769
|
| o  changeset:   64:625d08492555
| |  branch:      Cleanup
| |  parent:      62:eed6619dadb8
| |  user:        Alex Bream
| |  date:        Wed Nov 09 21:38:44 2011 +0600
| |  summary:     ╟рўшёЄър яю 1-1 155
| |
o |  changeset:   63:c778bae76563
|\|  parent:      61:e7ae9e5f725a
| |  parent:      62:eed6619dadb8
| |  user:        Alex Bream
| |  date:        Wed Nov 09 21:33:22 2011 +0600
| |  summary:     Merge with Cleanup
| |
| o  changeset:   62:eed6619dadb8
| |  branch:      Cleanup
| |  parent:      59:c9e3b41ec78f
| |  user:        Alex Bream
| |  date:        Thu Mar 03 19:19:34 2011 +0500
| |  summary:     ╟рўшёЄър яю 1-1 131
| |
o |  changeset:   61:e7ae9e5f725a
| |  user:        Alex Bream
| |  date:        Thu Mar 03 05:40:34 2011 +0500
| |  summary:     2-9 яю 2745
| |
o |  changeset:   60:1393fe759096
|\|  parent:      57:a38258cac9b8
| |  parent:      59:c9e3b41ec78f
| |  user:        Alexander
| |  date:        Thu Mar 03 04:59:22 2011 +0500
| |  summary:     Merge ё ўшёЄшыъющ
| |
| o  changeset:   59:c9e3b41ec78f
| |  branch:      Cleanup
| |  user:        Alexander
| |  date:        Thu Mar 03 04:54:11 2011 +0500
| |  summary:     ╟рўшёЄър яЁюыюу яюыэюёЄ№■
| |

并比较两种形式的转速集的输出(无论如何输出相同)

后代()
>hg log -r "descendants(c9e3b41ec78f)" --template "{rev}:{node|short}\n"
59:c9e3b41ec78f
60:1393fe759096
61:e7ae9e5f725a
62:eed6619dadb8
63:c778bae76563
64:625d08492555
65:f202d72d6397

直接范围定义
>hg log -r "id(c9e3b41ec78f):tip" --template "{rev}:{node|short}\n"
59:c9e3b41ec78f
60:1393fe759096
61:e7ae9e5f725a
62:eed6619dadb8
63:c778bae76563
64:625d08492555
65:f202d72d6397

关于mercurial - Hg - 查找 "cover"特定文件版本的标签,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8703653/

相关文章:

java - JSP : JSTL's <c:out> tag

mercurial - 我可以将对多个 mercurial 子存​​储库的更改提交到一个新的命名分支吗?

eclipse - MercurialEclipse 插件的官方/事件主页是什么?

linux - Mercurial 解包错误 : abort: . .. 未知包版本 20

html - 如何使图像在html表格中对齐?

text - iphone/ipod touch对canvas标签有什么样的支持?尤其是在文字方面?

iis - Windows 上的 Mercurial 服务器使用 Active Directory 进行身份验证

mercurial - 如何在远程存储库上运行 hg recovery 命令

css - 默认情况下哪些 HTML 元素样式排版不同?

javascript - 这个 Javascript 中的 "+e+"是什么意思?