Skip to content

Instantly share code, notes, and snippets.

@sixtusagbo
Last active March 19, 2024 06:51
Show Gist options
  • Save sixtusagbo/1ef227afb0000ecdbdcc446217cd9d35 to your computer and use it in GitHub Desktop.
Save sixtusagbo/1ef227afb0000ecdbdcc446217cd9d35 to your computer and use it in GitHub Desktop.
How to get a list of all the files that have been commited but not yet pushed
You can use the following Git command in your terminal to see a list of all files that have been committed but not yet pushed:
git diff --name-only origin/main

This command compares your local repository (including committed changes) with the main branch on the origin remote repository.

To view more statistics on it:
git diff --stat origin/main

The --stat option shows file change statistics, including the names of files that have changed.

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