Thank you! Good to know!

I think the problem was I never edit the commit message. I always use
"-m" because I'm more of a command line guy. I'll change my habit!

Sorry again about the accidental extra PR.

Cheers,
bzt

On 9/18/20, Peter Stuge <pe...@stuge.se> wrote:
> bzt wrote:
>> After Jenkins run, it reported an empty line at the end of one file.
>> I've fixed that, commit+push again. I though that's the normal flow
>> for fixing. But it created a new PR:
>> https://review.coreboot.org/c/coreboot/+/45483
>>
>> And this time it gives me "Merge conflict" error (obviously). How am
>> I supposed to fix a PR?
>
> By amending the original commit locally, keeping the original Change-Id
> line in the commit message, and pushing again.
>
> "Amend" is a specific git operation which replaces one commit with
> another commit with different (usually additional) changes.
>
> Rather than running 'git commit' to create a second commit on top of
> the first, you can run 'git commit --amend' to create a new commit
> that replaces the first, with the newly created commit adding more
> stuff to (or removing an empty line from) the first.
>
> Git lets you edit the commit message for the new commit as usual, but
> defaults to suggest the commit message that you created for the
> original commit, and that should already include the Change-Id line.
>
> If you are careful to retain that line, Gerrit then knows that this
> new commit is a fixed version of the previous change.
>
>
> Kind regards
>
> //Peter
>
> PS: To fix this situation at f238414, you could run git rebase -i 8d1b6be^
> and change "commit" in the f238414 line to "fixup", then save and exit.
> Git should then combine the two commits into one, as had you amended.
> _______________________________________________
> coreboot mailing list -- coreboot@coreboot.org
> To unsubscribe send an email to coreboot-le...@coreboot.org
>
_______________________________________________
coreboot mailing list -- coreboot@coreboot.org
To unsubscribe send an email to coreboot-le...@coreboot.org

Reply via email to