While working on another file, I edited README.md
and then ran git add README.md
. When doing a git commit, I see that README.md
is both in the "Changes to be committed" and "Changes not staged for commit".
Does this make sense? Where in .git
could I look to see the authoritative state of this file?
# On branch master
# Changes to be committed:
# (use "git reset HEAD <file>..." to unstage)
#
# modified: README.md
# modified: utils/arrterm
#
# Changes not staged for commit:
# (use "git add <file>..." to update what will be committed)
# (use "git checkout -- <file>..." to discard changes in working directory)
#
# modified: README.md
git add -p
you add only the first 5 changes. Now your file is also staged and not staged. – Still