9th Wed
Gitでコミット前の状態にもどす
今のコミット間違った―!というときに、コミット内容もなしにして戻すのがgit-reset --hard。
git reset --hard HEAD~3
Rewind the master branch to get rid of those three commits.
http://www.kernel.org/pub/software/scm/git/docs/git-reset.html
一つ前のコミットまで戻る時は、**HEAD^**を引数に渡すと戻ってくれます。
あーよかった!
posted by
satoko on Wed 9 Jul 2008 at 15:35 with 0 comments