For those of you who use GIT, you have probably noticed that while it is an incredibly powerful tool, one area that it could use some help is reporting. For example, Let’s say that I want to determine all changes to a file provided a date range… how would you do that? While there are many plugin utilities out there that provide reporting to GIT, very rarely will you find a utility that is able to generate the report you need at all times.
One thing that many people do not realize is that within GIT you can easily pipe the log to another application and quite literally build your own reports from within the command line. One of the more powerful applications that you can utilize is AWK, which allows you to write some code that parses through a log to generate a report to your needs.
Here are a few that I created to give you an idea of what you can do with this technique.
Determine how productive your team has been using git history.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
Determine all changes to a file provided a date range in GIT.
1 2 3 4 5 6 7 8 9 10
Determine the diff provided a Pivotal Tracker Story ID.
1 2 3 4 5 6 7
Determine all commits for a developer given a time range.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
I hope everyone finds this useful. Now use the comments to share your own GIT with AWK magic!