Finding most changed files in Git

前端 未结 9 1658
野的像风
野的像风 2020-11-29 15:24

How can I show files in Git which change most often?

9条回答
  •  Happy的楠姐
    2020-11-29 16:16

    Old question, but I think still a very useful question. Here is a working example in straight powershell. This will get the top 10 most changed files in your repo with respect to the branch you are on.

    git log --pretty=format: --name-only | Where-Object { ![string]::IsNullOrEmpty($_) } | Sort-Object | Group-Object  | Sort-Object -Property Count -Descending | Select-Object -Property Count, Name -First 10
    

提交回复
热议问题