You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Every time I teach this, participants ask how they can check to see whether origin has been updated before they try to git push so as to know in advance whether they're going to have to merge anything, or more generally just to compare their latest committed version with origin.
Is it worth adding a small exercise showing git fetch, and then how to compare master with origin/master?
The text was updated successfully, but these errors were encountered:
I agree. I also think it would be worth clarifying that git pull is equivalent to git fetch && git merge origin/<upstream-branch>. That would demystify git pull a bit, as well as clarifying the separation between merging branches and interacting with an upstream repo.
I think git fetch is starting to go into intermediate territory, which is out of scope for a novice lesson. Maybe if this were a full-day lesson, but since it isn't we need to be careful that this novice lesson doesn't go out of scope.