Skip to content
Build SVG charts from a Git repository.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.gitignore
.travis.yml
ChangeLog.adoc
LICENSE.txt
README.adoc
gitchart.py
setup.py

README.adoc

gitchart

Description

Gitchart is a Python script to build charts from a Git repository.

It can build following charts, as SVG or PNG:

  • authors (pie chart)

  • commits by hour of day, day, day of week, month of year, year, year/month (bar charts)

  • commits by hour of week (dot chart)

  • files by type (pie chart)

Requirements

Gitchart requires:

  • Python >= 2.7

  • Pygal (pip install pygal)

Optional dependencies:

  • cairosvg, to generate PNG files

Install

You can install gitchart with this command from the source repository:

$ python setup.py install
Warning
A fake and untrusted package called "gitchart" was added by an usurper on PyPI.
This is NOT an official gitchart package and was made without my authorization.
I can’t give any guarantee on its contents, so I don’t recommend to install this untrusted version.
Moreover, the "gitchart" organization on GitHub is a fork of this project with a different content (the official gitchart URL is https://github.com/flashcode/gitchart).
See the issue #5 for more information.

Usage

See output of command:

$ gitchart -h

Examples

Generate pie chart with authors:

$ gitchart -t "Git authors on project X" -r /path/to/gitrepo/ authors authors.svg

Generate bar chart with commits by year:

$ gitchart -r /path/to/gitrepo/ commits_year commits_year.svg

Generate bar chart with commits by version (git tag):

$ cd /path/to/gitrepo/
$ git tag | gitchart commits_version /tmp/commits_version.svg

Demo

Gitchart is used to build statistics for WeeChat: https://weechat.org/dev/stats/

Copyright © 2013-2019 Sébastien Helleu <flashcode@flashtux.org>

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see https://www.gnu.org/licenses/.

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.