コマンドラインから以下を確認した後:
# On branch RB_3.0.10
# Changed but not updated:
#   (use "git add <file>..." to update what will be committed)
#   (use "git checkout -- <file>..." to discard changes in working directory)
#
#       modified:   index.htm
次のコマンドを入力して、変更を破棄しようとしています。
git checkout -- index.htm
しかし、git statusを再実行すると、まったく同じに見えます。チェックアウトが機能していないようです。私は何か間違ったことをしていますか?Windows / cygwinでGIT 1.6.1.2を使用しています。
# On branch RB_3.0.10
# Changed but not updated:
#   (use "git add <file>..." to update what will be committed)
#   (use "git checkout -- <file>..." to discard changes in working directory)
#
#       modified:   index.htm
git checkout HEAD -- index.htm私のために働いた!
                
git checkout HEAD -- index.htm(代わりにインデックスからチェックアウトすると、最後にコミットされた状態からチェックアウト)動作しますか?