When I choose a open-source software from several projects, I’d want to choose more active one. Although some repository service like Google Code provides “activity” information, that was not enough for me because:
So, I wrote a simple Python script to plot a histogram of commit frequency (number of commit per day).
The figure bellow is an example. It is the histogram of the Numpy repository. You can see, for example, that it became very active since 2006.
For your information, this Python script can read any (point process) data if it is a sequence of an unix time per line. Please let me know if you have some other use of this script!
You can find the script at tkf’s gist: 913543 — Gist or bottom of this post.
Execute this at working directory of the repository of which you want to know the commit frequency.
hg log --template '{date}\\n' | datehist.py
git log --format='%at' | datehist.py
datehist.py
can read the data (the output of hg log
or git log
) like this from stdin:
1298586880
1298516219
1298426531
1298426393
1298418897
1298407083
1298387222
1298387170
1295910432
(... and so on)
This is a sequence of unix time separated by new line \n
.
You can specify the plot title from the command line option -t
. For example, if you want to use the full path of the working directory as the title:
hg log --template '{date}\\n' | datehist.py -t `hg root`
git log --format='%at' | datehist.py -t `git rev-parse --show-toplevel`
I compared the following projects:
Hmmm… Looks like none of them is very active.
I’m using b for some reason.
You can get the newest one from tkf’s gist: 913543 — Gist.
Note: It looks like you need a local repository to see its log.