* 取り消したコミットの内容を確認する [#t8754cb8]

** (git resetしたが)その取り消したコミットの内容を確認する [#t1179f18]

*** 方法 1 [#u03f5700]
 git reset --soft HEAD^
 git show ORIG_HEAD

*** 方法 2 [#ia4f8fa2]
 vi test.txt                 # (1) test.txtを修正する。
 git add test.txt            # (2) これをステージングして、
 git commit -am 'fixed'      # (3) コミットする。
 git reset --hard HEAD^      # (4) このコミットを取り消す。
 vi test.txt                 # (5) 再度、test.txtを修正する。
 git diff ORIG_HEAD test.txt # (6) (1)の修正とのdiffを見る。

トップ   編集 差分 バックアップ 添付 複製 名前変更 リロード   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS