Skip to content

Instantly share code, notes, and snippets.

@agassner
Created August 14, 2013 19:20
Show Gist options
  • Save agassner/6234552 to your computer and use it in GitHub Desktop.
Save agassner/6234552 to your computer and use it in GitHub Desktop.
patching with git
# create a patch
git diff --no-prefix > patchfile
# apply a patch
patch -p0 < patchfile
# apply a patch created without "--no-prefix"
patch -p1 < patchfile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment