【问题标题】:List files changed in Git with change information [duplicate]使用更改信息列出在 Git 中更改的文件 [重复]
【发布时间】:2023-03-18 03:54:02
【问题描述】:

简而言之,我想要这个:

git show --name-only <hash>

(How to list all the files in a commit?)

但我也想知道它是什么类型的变化,例如添加、删除、添加/删除 n 行,最好仍然在每个文件的一行中。

【问题讨论】:

    标签: git git-show


    【解决方案1】:

    git diff-tree <hash> --stat --summary

    --stat 显示添加/删除的行数,而--summary 明确显示添加和删除的文件。

    【讨论】:

      猜你喜欢
      • 2012-07-19
      • 2015-08-23
      • 1970-01-01
      • 2014-07-11
      • 2018-03-30
      • 2013-08-15
      • 2010-10-30
      • 2011-06-20
      • 1970-01-01
      相关资源
      最近更新 更多