Git reset -p on working tree
- From
Jeenu V <jeenuv@gmail.com>
- Date
- Nov 23, 2010, 09:11 UTC
- Message-ID
- <AANLkTimc=Dt9YSu=J=7C-f1hZ9UODU7VHu6oD8dmFX3N@mail.gmail.com>
Often I find it useful to selectively undo the modifications that I did to my working tree. The -p option to 'reset' that selectively resets changes back to a given commit. Unfortunately the option reports itself to be incompatible with --{hard,soft,mixed} and thus can't be applied to working tree.
Right now I do this with vimdiff, by applying 'git diff' in reverse. Wish reset supports -p on working tree operations as well because the -p framework (of add, and reset) feels good to use.
-- Jeenu