Home
Main website
Display Sidebar
Hide Ads
Recent Changes
View Source:
PatchNotes
Edit
PageHistory
Diff
Info
LikePages
Lets say you've fixed a bug in a piece of software, and you now want to share your fix with the "upstream" author or distribution packager, so that you don't need to keep applying this patch to new versions, and that other people can benefit from it. * Use "cvs diff -u" to generate the patch if you got the source from cvs(1) - everyone knows what that is. Developers have scripts to automatically apply a "cvs diff -u" style patch (figuring out -p properly etc). [CVS] also tells you what versions things are applied against, if people need to work back towards what versions you have. Otherwise (if it didn't come from cvs) do a "<tt>diff -u</tt>" from the top level directory of the /modified/ rather than in the cwd of the /original/. This means that normally you can just apply the patch with "<tt>patch -p0</tt>" and it "just works". * Send it as an attachment unless explicitly asked otherwise. Otherwise your patch might get wordwrapped and this can cause a lot of confusion. * It's often sensible to use the extra flags -w and -b to diff to ensure that you're not changing extraneous whitespace in your patch. See the patch(1) and diff(1) ManPage~s for usage and descriptions of the options. ----- CategoryNotes
One page links to
PatchNotes
:
patch(1)