Re: feature request: git add--interactive --patch on regex-matched hunks only
- From
Nguyen Thai Ngoc Duy <pclouds@gmail.com>
- Date
- Jul 26, 2011, 13:03 UTC
- Message-ID
- <CACsJy8C822Fvwav4Wpw4e-12ZY20XM1s2v4KymZkaDYLxkMHvw@mail.gmail.com>
- In-Reply-To
- <CACsJy8Birqg2Ldp1Mt4NWOq1aT0oigTcFA8S=RWcK5y+zstwDA@mail.gmail.com>
It would be even more cool if --hunks (or whatever the name will be) could work without -p. I mean, if "git diff" supports it, then I can fine tune my regex to meet a selection of hunks I want, and verify it really is what I want. Then "git add --hunks=magic" and voila! (The "git add --hunks" without -p surely can be workaround by adding "-p", then accept all hunks).
And if diff machinery learns this, we would have "git log --hunks" too.
OK I'm asking too much..
-- Duy