Git: Is an unpushed commit just files in the index?

204 Views Asked by At

This may be a misnomer in the tool I am using (Code Collaborator) but it gives the choice of adding "unpushed commits" or simply "commits."

I would have thought a pushed commit is a commit pushed to origin whereas an unpushed commit would have been files locally added and then committed. But it seems like unpushed commits might just be files added but not yet committed locally whereas commits are both added and committed locally but not pushed to origin. So is this a standard way to refer to state of files in Git?

1

There are 1 best solutions below

1
On

Unpushed commits are commits (as in git add then git commit) that are on your local branch, but not git push to the remote.

Code collaborator will not upload changes that are staged or unstaged using this option, only committed.

When you select "Add Commits" you will enumerate all of the commits, by ID, that you want to include in the review.

When you select "Add Unpushed Commits" it will upload all commits that are on your local branch, but have not been pushed to the remote.