this is brilliant idea. thanks :)

On Fri, Sep 25, 2009 at 12:33 PM, Jeenu <jee...@gmail.com> wrote:
>
>
> On Sep 25, 8:15 am, "davidshe...@googlemail.com"
> <davidshe...@googlemail.com> wrote:
>> hi,
>>
>> i found i made a typo error in a commit message which is many commits
>> away from current HEAD, how can i amend the message? i tried git
>> commit --commit <my commit hash>, but it created an new commit and
>> advanced my HEAD.
>
> May not be the best, but you can try this:
>
> * After switching to your brach, do "git rebase -i <your commit>"
> * In the edited, change "pick <your commit>" to "edit <your commit>,
> and close the editor
> * The rebase operation will pause for you. At that point it's in a
> state where you made <your commit>
> * You can now do a "git commit --amend", edit your commit message and
> perform the commit as usual
> * Once you're done, you can finish the rebase with "git rebase --
> continue"
>
> HTH
> :J
> >
>



-- 
Best Regards,
David Shen

http://twitter.com/davidshen84/
http://meme.yahoo.com/davidshen84/

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To post to this group, send email to git-users@googlegroups.com
To unsubscribe from this group, send email to 
git-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/git-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to