0%

查找指定 commit 之间修改文件列表

使用 git diff 查看指定 commit 之间修改文件列表

使用 ccat 为例

$ git diff --name-only <SHA, tag start> <SHA, tag end>
$ git diff --name-status <SHA, tag start> <SHA, tag end>
$ git diff --name-only 561b2d4 7cf6d90
.travis.yml
README.md
completion/zsh/_ccat

$ git diff --name-status 561b2d4 7cf6d90
M       .travis.yml
M       README.md
A       completion/zsh/_ccat

然后查看文件的具体改动

$ git diff 561b2d4 7cf6d90 .travis.yml
diff --git a/.travis.yml b/.travis.yml
index e4fed32..008ab1c 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,5 +1,8 @@
 sudo: false
 language: go
 go:
-  - 1.8.3
+  - 1.8.x
+  - 1.9.x
+  - 1.10.x
+  - 1.11.x
 script: ./bin/test