gitstats
gitstats copied to clipboard
Unable to install gitstats on macOS
Folloing instructions from http://gitstats.sourceforge.net/, I tried to install gitstats
with command
brew install --HEAD homebrew/head-only/gitstats
But got this error:
Error: homebrew/head-only was deprecated. This tap is now empty and all its contents were either deleted or migrated.
Related issue:
https://github.com/hoxu/gitstats/issues/55
Indeed, Homebrew won't help you here, since Python 2 is deprecated, see:
- https://www.python.org/doc/sunset-python-2/
- https://docs.brew.sh/Homebrew-and-Python
On a recent version of macOS, you will need to:
- download latest version of Python 2 from https://www.python.org/downloads/release/python-2718/ – and install
- install gnuplot, e.g. using
brew install gnuplot
(have not tested this yet, there may be incompatibilities, since gitstats is a bit outdated)
The installation provided by brew is outdated, so it is recommended to install it locally and then install the relevant dependencies.
- git clone [email protected]:hoxu/gitstats.git
- brew install gnuplot
- Install Python (>= 2.6.0)
After the above is completed, execute:
$ ./gitstats /mnt/src/git/project ~/public_html/project
(go grab a cup of coffee if it's a large project :)
$ sensible-browser ~/public_html/project/index.html
Have a good time ~