Skip to content

Latest commit

 

History

History
9 lines (5 loc) · 944 Bytes

patch-phase.md

File metadata and controls

9 lines (5 loc) · 944 Bytes

You should not override patchPhase.

patchPhase is responsible for applying patches so if you override it without carefully replicating the original behaviour, you will likely confuse someone trying to add a patch to patches in the future.

Add your commands to postPatch hook instead.

Avoid using prePatch too. It might change the source code so that the patches in patches no longer apply and when that happens, it is often easier to handle the conflict by tweaking a command in postPatch than modifying a patch.

If you need to pass some arguments to patch call, for example, to handle non-standard paths using -p0, using fetchpatch to modify the patch might be nicer.