gitによる変更履歴の確認関連

特定ファイルの変更履歴を見る

git log -p /path/to/file

特定ディレクトリの変更履歴も同様に行ける

Gitで特定ファイルの変更履歴をみる - Bye Bye Moore

man git-log してみると,full-diff optionの説明があり,そこにpオプションの動作についての記述が出てくる.

--full-diff
           Without this flag, git log -p <path>...  shows commits that touch the specified paths, and diffs about the same specified paths. With this, the full diff is shown for commits that touch
           the specified paths; this means that "<path>..." limits only commits, and doesn’t limit diff for those commits.

--full-diffを付けない場合は特定のファイル(ディレクトリでも良いのでパスと呼んでる)にtouchしたコミットとそのファイルに関するdiffを表示し, 付ける場合はファイルにtouchしたコミットと,そのコミットに関するdiffを表示する.

つまり,後者の場合は指定したファイル以外に関するdiffも表示される(指定されたファイルが含まれるcommitにある,他のファイルに関するdiffも表示される)

細かすぎるなこれは・・・ ここまで調べる必要無かったかもだが,深追いするクセでまたやってしまった.