Mercurial 承诺与实际生产图
好吧,我还没有看到这个弹出窗口是关于 Mercurial 的综合问题,但这是我最近注意到的。
当查看开发软件的其他存储库时,提交几乎是“理想的”,因此如果目标是修复函数 f(),那么提交只是“通过 --- 修复 f()”。我的事情是,我怀疑每一次修正都是在一次提交中发生的。
我会有类似
[1:尝试 x 修复 f] -> 的 内容[2:尝试 y 修复 f] -> [3:尝试用 z 来修复 f] -> [4:f 固定]
我注意到有或没有命名分支,如果我尝试将 [4:fixed] 合并到我拥有的“稳定”分支,那么无论是推送还是拉动更改,它都不会拉动 [1:4]只是[4]。
我只想对存储库或生产设置进行彻底的更正。共享所有非测试更改的最简单方法是什么?
Ok, I've yet to see this popup as a combined question on mercurial, but it's something I've noticed recently.
When looking at other repos for development software, the commits are pretty much 'ideal' so if the objective was to fix a function f() then the commit is just 'fixed f() by ---'. My thing, I doubt every correction took place in just a single commit.
I would have something like
[1:trying x to fix f] -> [2:trying y to fix f] -> [3:trying z to fix f] -> [4:f fixed]
I noticed with or without named branches, if I try to then merge [4:fixed] to the 'stable' branch I have, then whether pushing or pulling the change, it pull [1:4] not just [4].
I would only want to push a clean correction to a repo or to a production setup. What's the easiest way to share all of my non-test changes?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
rebase 扩展 与
--collapse
。The rebase extension with
--collapse
.如果您只想推送一个干净的变更集,则只创建一个干净的变更集。将多个本地变更集折叠为 1 个(a Amber 的答案)是一种方法。
我更喜欢的方式是使用 Mercurial 队列并在补丁中完成我的工作。然后,当它完成时,我完成补丁并成为变更集。
If you only want to push a clean changeset, only make a clean changeset. Collapsing multiple local changesets into 1 (a la Amber's answer) is one way.
The way I prefer is to use Mercurial Queues and do my bits of work in a patch. Then when it is complete I finish the patch and becomes a changeset.