Git Study Notes 4 find the lazy programmer

Source: Internet
Author: User

Scenario hypothesis: A development team has 10 programmers who use Git for version control. One day, after programmer A pushes several commits of the day, I suddenly wondered, "How many times have I performed a commit in this project? Who is more than me commit? How many more? Who is the most commit in the group? Who is the least ?"

Git supports a very user-friendly command: $ git commit log

This command returns the number of times that each user under the git repository performs the commit operation and comments for each commit operation.

The-s parameter ignores comments of each commit and returns only a simple statistic.

-N parameters are sorted by the number of commit values from large to small.

$ Git commit log-s-n
135 Tom Preston-Werner
15 Jack Danger Canty
10 Chris Van Pelt
7 Mark Reid
6 remi
3 Mikael Lind
3 Toby DiPasquale
2 Aristotle Pagaltzis
2 Basil Shkara
2 John Reilly
2 PJ Hyett
1 Marc Chung
1 Nick Gerakines
1 Nick Quaranto
1 Tom Kirchner

For example, I want to know the commit statistics of an open-source project (such as Graphiti ).

The results show that a buddy named Michael Wenz on the Graphiti forum is indeed the main developer of this open-source project.

Author: qinjienj

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.