变基和力量推动后,我有一个分离/晃来晃去的提交/标记 - After rebase and force push, I have a detached/dangling commit/tag

- 此内容更新于:2016-02-03
主题:

事件:新分支的主人:“rollback-appcompat”工作,把一个标签在最后提交“1.8.1.13”工作的主人,现在我想变基我的新分支大师之好,但不能推动远程根据这个,我可以简单的力量推动,所以我这样做。现在我在一个有趣的情况下我仍然有分支之前重置现有这样的:正如你所看到的,紫色是“rollback-appcompat”之前重置。我怎么去掉?我认为它没有删除,因为我有一个标签,这是正确的吗?

原文:

What happened:

  • New branch off master: "rollback-appcompat"
  • Work on it and put a tag on the last commit "1.8.1.13"
  • worked on master, now I want to rebase my new branch on master
  • Rebased fine, but couldn't push to remote
  • According to this, I could simply force push, so I did that.
  • Now I'm in a funny situation where I have the branch before it was rebased still existing like this:

enter image description here

As you can see, the purple is "rollback-appcompat" before it was rebased. How do I get rid of that? I think it wasn't removed because I had a tag on it, is that correct?

网友:这是远程公开吗?因为公共历史重写会坏……像穿越流。

(原文:Is this remote public? Because rewriting public history would be bad... like crossing the streams.)

网友:[…]这不是删除,因为我有一个标签,这是正确的吗?正确的。可接触的所有承诺,这个标签将显示在您的日志。你可以标记移动到相应提交重置分支的祖先……但是公共移动标签,像公共历史重写,被认为是不好的做法。

(原文:[...] it wasn't removed because I had a tag on it, is that correct? Correct. All the commits that are reachable from this tag will be visible in your log. You could move the tag to the corresponding commit in the rebased branch's ancestry... but moving public tags, like rewriting public history, is considered bad practice.)