Is there a command I can run to check if there is any commits to push to origin/master?
git [some command] origin master
Would output something like:
origin/master is behind by 7 commits
Here are two ways to list the "extra" commits you have which are not on origin/master:
git log --oneline origin/master..HEAD
git rev-list --oneline ^origin/master HEAD
The --oneline
just lists them in a shorter format. Also, if your branch tracks origin/master, a simple git status
will show you.