git gerrit 中的“放弃更改”按钮究竟是什么?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/17047106/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-19 08:36:50  来源:igfitidea点击:

What exactly is the button "Abandon Change" in gerrit?

gitcontinuous-integrationgerrit

提问by user2474895

I didn't find any documentation that can help me out. Can I push to review one commit then another and then abandon first and submit second? We're using Git on our project.

我没有找到任何可以帮助我的文档。我可以推动一个提交然后另一个提交,然后先放弃然后再提交吗?我们在我们的项目中使用 Git。

回答by Rasmus ?stergaard Kj?r Voss

There is some documentation regarding the abandon optionfor command review.

有一些关于命令的放弃选项的文档。

But essentially abandon abandons the change, so it can no longer be committed to the branch unless it is restored.

但是基本上放弃放弃更改,因此除非恢复它,否则它不能再提交到分支。

The change will no longer be counted as an open review, when it is abandoned.

当更改被放弃时,将不再被视为公开。

回答by Arye Shemesh

This cannot be done. Once you have an abandoned commit you must remove the dependency of future commits on it. Here's an answerthat can tell you how to do it.

这是不可能的。一旦你有一个放弃的提交,你必须删除未来提交对它的依赖。这是一个可以告诉您如何操作的答案