git diff
compares the working tree (the files on disk) to the index (the staged modifications).
AFAIK, it isn't the shorthand of any other compbination of arguments.
The examples section of the documentation explains pretty well the subtleties around the "compare the latest changes" commands :
Various ways to check your working tree
$ git diff (1)
$ git diff --cached (2)
$ git diff HEAD (3)
- Changes in the working tree not yet staged for the next commit.
- Changes between the index and your last commit; what you would be committing if you run
git commit
without -a
option.
- Changes in the working tree since your last commit; what you would be committing if you run
git commit -a
In that list : (2)
is a shorthand for git diff --cached HEAD
, but I don't know of any other way to write (1)
or (3)
.