[Insight-developers] Just when I thought I understood gerrit

Bill Lorensen bill.lorensen at gmail.com
Mon Nov 8 15:47:40 EST 2010


Marcus,

That did it!. I must have missed that in the documentation?

Bill

On Mon, Nov 8, 2010 at 3:25 PM, Marcus D. Hanwell
<marcus.hanwell at kitware.com> wrote:
> On Mon, Nov 8, 2010 at 2:45 PM, Bill Lorensen <bill.lorensen at gmail.com> wrote:
>> Marcus,
>>
>> I tried to push a patch to an existing topic. Here is what I did:
>>
>> 1) git fetch http://review.source.kitware.com/p/ITK
>> refs/changes/02/302/2 && git checkout FETCH_HEAD -b
>> ConstShapedNeighborhoodIterator-ExposeSuperclass-Methods
>>
>> 2) Edited file, compiled.
>>
>> 3) git commit -m "BUG: Misnamed typedef."
>> Testing/Code/Common/itkConstShapedNeighborhoodIteratorTest.cxx
>>
>> 4) git rebase -i HEAD~2
>>   Changed commit message. Picked first commit, squashed second
>> commit. Retained first ChangeId.
>>
>> 5) git gerrit-push
>>
>> I get a new entry on gerrit, rather that a patch to the existing one.
>>
>> I swear I have done this several times. Even once to the topic I'm
>> trying to patch.
>> http://review.source.kitware.com/#change,302
>>
>> You will see several abandoned topics that show my attempts.
>>
>> Where did I go wrong?
>>
> The Change-Id line *must* be the last line of the commit message. You
> put something after the Change-Id line (BUG: Misnamed typedef.) If you
> simply move that up to before the Change-Id line then it would work.
> Gerrit only uses the final line of the commit message to scan for
> Change-Id lines.
>
> Marcus
>


More information about the Insight-developers mailing list