Skip to content

Instantly share code, notes, and snippets.

@jepio
Last active August 29, 2015 14:03
Show Gist options
  • Save jepio/26f45ffefc556ec815c0 to your computer and use it in GitHub Desktop.
Save jepio/26f45ffefc556ec815c0 to your computer and use it in GitHub Desktop.
Create and apply a patch
diff -u file file_updated > file.patch # creates a patch describing the changes between two files
patch < file.patch # applies the patch to file, making it the same as file_updated (won't change the filename)
@jepio
Copy link
Author

jepio commented Jun 27, 2014

Next step is figuring out how to do this in Git.

@jepio
Copy link
Author

jepio commented Mar 7, 2015

And don't forget this link diff-patch-ten-minutes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment