Creating a patch

This page provides an overview on patches and patching best practices. The usage of patches by portage and it's ebuilds is covered under Portage : Patches and there is a related stub under Developers : Patches.

TortoiseGit and Git for Windows
Patches generated by [//tortoisegit.org/docs/tortoisegit/tgit-dug-patch.html Tortoise Git] and Git for Windows are padded with additional information that  does not understand.

The individual generating the patch has to strip these additional lines to make a viable patch file.

Nesting
If the file(s) being patched are not unpacked into the root of the working directory,, but rather some sub-directory of the working directory, , then the patch must be modified to accommodate it.

External resources

 * How to write clean patches when not using git-format-patch.
 * The developer manual also discusses patches