G:\mygitea\GitLearn\learn03 master ± $ vim readme
G:\mygitea\GitLearn\learn03 master ± $ git status On branch master Changes not staged for commit: (use "git add <file>..." to update what will be committed) (use "git restore <file>..." to discard changes in working directory) modified: readme
no changes added to commit (use "git add" and/or "git commit -a")
G:\mygitea\GitLearn\learn03 master ± $ git diff --cached diff --git a/readme b/readme index 93d277f..d371e8e 100644 --- a/readme +++ b/readme @@ -2,3 +2,4 @@ This is the oldest branch. This is the older branch. This is the young branch. after test, update readme. +test HEAD and cached compare.