Skip to content

Instantly share code, notes, and snippets.

@TerraTech
Forked from alh13/gist:3856276
Last active November 26, 2018 20:21
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 TerraTech/86cdf8fa5c29df3d8ff8a2247739cb2f to your computer and use it in GitHub Desktop.
Save TerraTech/86cdf8fa5c29df3d8ff8a2247739cb2f to your computer and use it in GitHub Desktop.
git-merge branch A into branch B so that B becomes EXACT copy of A
git merge --no-commit other-branch && git checkout other-branch -- . && git commit
### https://twitter.com/adymitruk/status/69479850846593024
# We needed this once after some intense debugging on the staging branch. We knew
# staging was correct and wanted to merge staging -> production and be sure that
# prod branch never "won" any conflicts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment