{"thread":{"id":"5415","subject":"git-apply --reject","startedAt":"2006-08-27T23:03:40Z","lastAt":"2006-08-27T23:03:40Z","messageCount":1,"participants":["Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"26015","messageId":"7vac5pvl0z.fsf@assigned-by-dhcp.cox.net","threadId":"5415","inReplyTo":null,"subject":"git-apply --reject","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-08-27T23:03:40Z","receivedAt":"2006-08-27T23:03:40Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"The git-apply program in \"next\" has had a few additional options\nfor some time: --reject and --verbose.  I've been using this\nafter a failed \"git am\" attempt:\n\n\tgit apply --reject --verbose .dotest/patch\n\nThis, instead of the usual \"patch does not apply so I would not\ntouch any of your working tree files\" behaviour, applies hunks\nthat are applicable and leaves *.rej files the rejected hunks,\nand it reports what it is doing. With --index, files with a\nrejected hunk do not get their index entries updated at all, so\n\"git diff\" will show the hunks that successfully got applied.\n\nThis seems to be working rather nicely, so I intend to make it\ngraduate to \"master\".  I made a mistake of adding the man page\nthat already talks about these options to \"master\", but with an\nincorrect the description for --reject (earlier I planned to\nsend the rejected hunks to stdout which is still what the\ndocumentation describes), so the documentation will be updated\naccordingly.\n\nI initially made --reject without --verbose not talk about\nanything that applied cleanly, but as the above example usage\nshows, I find myself always using --verbose when using --reject.\nWithout --verbose to remind the user that the patch updated some\nother paths cleanly, it is very easy to lose track of the status\nof the working tree.  So I'll make the final adjustment to make\nit imply --verbose before pushing it out.\n"}]}