ログを確認
概要
「git log」でログを確認する
手順
基本的なログ
hoge@WKPC-MSHIGE1979 /d/demos/git_repo (master)
$ git log
commit 8ef56863e99e0eb2e0204d66842a2e05b8662fe0
Author: sample01 <sample01@hogehoge.com>
Date: Sat Oct 27 06:49:05 2012 +0900
text file add line
commit 8742fb8ebf8d1c4c80ca79dc547a738c4976c9e3
Author: sample01 <sample01@hogehoge.com>
Date: Sat Oct 27 06:40:35 2012 +0900
test commit
commit 4bbfd60ec3fea365d4bcc9fb6a2881022dfb9909
Author: sample01 <sample01@hogehoge.com>
Date: Thu Oct 25 23:53:47 2012 +0900
test1
hoge@WKPC-MSHIGE1979 /d/demos/git_repo (master)
$
※基本はコミットID、ユーザー、日時、コメントを表示
1行のみの表示
hoge@WKPC-MSHIGE1979 /d/demos/git_repo (master)
$ git log --oneline
8ef5686 text file add line
8742fb8 test commit
4bbfd60 test1
hoge@WKPC-MSHIGE1979 /d/demos/git_repo (master)
$
※--onelineを指定することでコミットIDを7桁に短縮して、コメントのみで出力する
コミットIDによる比較
hoeg@WKPC-MSHIGE1979 /d/demos/git_repo (master)
$ git diff 8ef5686 8742fb8
diff --git a/testdata.txt b/testdata.txt
index 0c10f4b..2819241 100644
--- a/testdata.txt
+++ b/testdata.txt
@@ -2,4 +2,3 @@ aaaaaaa
bbbbbbbbb
cccccccccc
dddddddddd
-<95>ύX<93><E0><97>e<82>ł<B7>
hoge@WKPC-MSHIGE1979 /d/demos/git_repo (master)
$
※「git diff」でコミットIDを指定することで差分を確認できる(マルチバイト文字が正しく表示されないかも)
最終更新:2012年10月27日 07:05