如何更改 Mercurial 中的默认版本?
当我克隆
以下项目时
http://code.google. com/p/signal-detector/source
它位于标记为 default
的修订版中,这不是最新的也不是 tip
修订版。
我尝试了多次合并以使最新版本成为默认版本,但我做不到。
怎么做呢?
When I clone
the following project
http://code.google.com/p/signal-detector/source
it comes in the revision marked as default
, that isn't the latest nor the tip
revision.
I tried many merges to make the latest revision to become default, but I couldn't.
How to do that?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
我想我明白发生了什么,您创建了一个名为
default
的标签,但您不应该这样做。在没有标签的情况下,default
会为您提供分支名称为default
的最尖端变更集。但是,由于您有一个名为default
的标记,该标记指向修订版 c257bbab2cf6c87b2c212aadbdd76f14c71e1ee2,因此您将其作为默认更新。删除标签:
我想你会得到你所期望的行为。
I think I see what happened, you created a tag named
default
and you shouldn't. In the absence of a tagdefault
gets you the most tip-ward changeset with the branch namedefault
. However, since you have a tag nameddefault
that points to revision c257bbab2cf6c87b2c212aadbdd76f14c71e1ee2 you're getting that as the default update instead.Delete the tag with:
and I think you'll get the behavior you're expecting.
试试这个:
try this:
我假设您看到的
default
标记与修订版无关,而是与您正在处理的分支有关。话虽如此,请通过键入以下内容检查当前的活动头:如果您有多个头,则意味着您尚未将所有内容合并回实际分支的核心行。
如果是这种情况,请提交所有工作(这将自动落入新的临时分支)。然后,从源中提取最后一个修订版本,然后合并:
如果在提取/合并阶段出现问题,请尝试通过发出以下命令将当前存储库更新为干净的存储库:
然后重试合并操作。
我可能误解了你的问题,因为我无法掌握你所有的环境状态,如果是这样,请原谅。
I assume the
default
tag you see isn't about the revision but the branch you're working on. That being said, check your current active heads by typing this:If you've got multiple heads, that means that you haven't merged everything back to the core line of the actual branch.
If it is the case, commit all your work (which will fall automatically into a new temporary branch). Then, pull the last revision from the source and then merge :
If there is a problem while on the pull/merging stage, try updating your current repository to a clean one by issuing this command:
And then retry the merge operation.
I may have misunderstood your problem since I couldn't grasp all of your environment status, if it is the case, please excuse me.