Which Git commit stats are easy to pull

前端 未结 13 1766
面向向阳花
面向向阳花 2020-12-12 11:23

Previously I have enjoyed TortoiseSvn\'s ability to generate simple commit stats for a given SVN repository. I wonder what is available in Git and am particularly interested

13条回答
  •  囚心锁ツ
    2020-12-12 11:42

    Thanks to hacker for answering this question. However, I found these modified versions to be better for my particular usage:

    git log --pretty=format:%an \
    | awk '{ ++c[$0]; } END { for(cc in c) printf "%5d %s\n",c[cc],cc; }'\
    | sort -r
    

    (using awk as I don't have gawk on my mac, and sorting with most active comitter on top.) It outputs a list like so:

     1205 therikss
     1026 lsteinth
      771 kmoes
      720 minielse
      507 pagerbak
      269 anjohans
      205 mfoldbje
      188 nstrandb
      133 pmoller
       58 jronn
       10 madjense
        3 nlindhol
        2 shartvig
        2 THERIKSS
    

提交回复
热议问题