Skip to content

Instantly share code, notes, and snippets.

@gte445e
Last active August 2, 2018 19:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gte445e/e39c95cc1b32fa41e4ed8634b2e97bd6 to your computer and use it in GitHub Desktop.
Save gte445e/e39c95cc1b32fa41e4ed8634b2e97bd6 to your computer and use it in GitHub Desktop.
Apply commit from another repository
# Is it possible to cherry-pick a commit from another git repository?
# https://stackoverflow.com/questions/5120038/is-it-possible-to-cherry-pick-a-commit-from-another-git-repository
git --git-dir=../<some_other_repo>/.git \
format-patch -k -1 --stdout <commit SHA> | \
git am --no-3way -k
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment