Let i have these commits:

* bbbbbbbb task #2850
* aaaaaaaa task #2850 - #2961

Then i fixuping last commit:

git commit --fixup=bbbbbbbb

* bfbfbfbf fixup! task #2850
* bbbbbbbb task #2850
* aaaaaaaa task #2850 - #2961

And I perform interactive rebase. Result will be:

* p bbbbbbbb task #2850
* f bfbfbfbf fixup! task #2850
* p aaaaaaaa task #2850 - #2961

Fixup plased after wrong commit. Yes, this behavior is documentated:
git rebase -i --autosquash places fixup|squash commits after "a commit 
whose title begins with the same …". (see rebase options 
--autosquashdescription)

But why commit --fixup make this? Why not use SHA in fixup commit message 
like this?

git commit --fixup=bbbbbbbb

* bfbfbfbf fixup! bbbbbbbb
* bbbbbbbb task #2850
* aaaaaaaa task #2850 - #2961

And I perform interactive rebase. Result will be:

* f bfbfbfbf fixup! bbbbbbbb
* p bbbbbbbb task #2850
* p aaaaaaaa task #2850 - #2961

And it is what i expect.
So, using commit message by default in creating fixup commits is trustless.
May be there is an option to use SHAs instead commit messages? I dont found 
it.

Thanks.

-- 
You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to git-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to