An excuse to use the git2go API and track what repositories are the most used.
You need to install:
By default looks for the $GIT
env var. If it's defined, points to the main
directory where you keep all your git repositories.
In case it's not found, you may provide a directory with the flag -g
.
In this example I provide an env var for all my Go projects.
There are some things to improve:
- The number of days whereby a repository is marked as abandoned is 90 days. This is harcoded, it could be easily move to an external config file.
- If the number of days is zero, mark as active.
- Add flag to provide branch you are interested in, only those repositories are listed.