Skip to content

Instantly share code, notes, and snippets.

@nepsilon
Created December 12, 2016 10:14
Show Gist options
  • Save nepsilon/733fba74deff2e16fa74353418b18a27 to your computer and use it in GitHub Desktop.
Save nepsilon/733fba74deff2e16fa74353418b18a27 to your computer and use it in GitHub Desktop.
Where to find changes due to git fetch — First published in fullweb.io issue #78

Where to find changes due to git fetch

fetch is useful to pull changes from an upstream repo to merge some changes. By default git fetch upstream will update or create all the remote branches locally.

Say you have upstream/master tracked by your local master branch. Here is how to see the changes between both:

git log master..upstream/master

This essentially means "all commits from upstream/master excluding commits from local master". For more info see gitrevisions(7).

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