I staged and committed 5 files and pushed it gerrit, but before it is merged in to git, I updated 3 of them then I git commit --amend to the last commit, and if I do push to gerrit again, does this second path contains the updates in the other two files?

有帮助吗?

解决方案

One thing you need to take care of before pushing your changes to Gerrit is that you have the commit-msg hook setup in your local repository. This will add a Change-Id to your commit message that Gerrit will then use to make sure your second push is a second patchset to your first change and not a new change. It is recommended that you setup your repository in such a way that pushed will be rejected if no Change-Id is found in your commit message

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top