My two favourite bits of git add -p that aren't mentioned here:
the / (search) command to search unstaged hunks for a specific keyword rather than having to jump through all the individual changes you've made when there's lots.
and the e (edit) command to manually split out two changes that end up in one hunk that I'd rather have in individual commits.
the / (search) command to search unstaged hunks for a specific keyword rather than having to jump through all the individual changes you've made when there's lots.
and the e (edit) command to manually split out two changes that end up in one hunk that I'd rather have in individual commits.