It's a fairly easy change on a perl file to make this happen. I would only recommend doing this if you don't like the default git-add -p
behavior of patching all files.
Find your copy of git-add--interactive
and open with your favorite editor. Go to the patch_update_cmd subroutine. In there, there is an if statement which tests $patch_mode
. Remove the top part of the if statement or set it so that the conditional always evaluates to false. Save and test.
An example of what I did to make this work follows.
if (0) {
@them = @mods;
}
else {
@them = list_and_choose({ PROMPT => 'Patch update',
HEADER => $status_head, },
@mods);
}
Another possible point of change would be at the very bottom of the file. You can change $patch_mode
to some false value after the if statement, the effect should be the same.
Note you may have some issues if you're using a package manager or something else similar which tracks installed packages, I'm not sure.