@hyperjumptech/export-github-clones-views
v0.0.1
Published
A CLI to export the stats of clones and views of repositories
Downloads
4
Maintainers
Keywords
Readme
export-github-clones-views
About
This is a CLI to fetch the daily number of clones and views of one or many github repositories. You can run this script regularly to track the traffic of clones and views of your repositories in a long term since the data shown in a Github repository website cannot be exported and only shows up to few days back.
Prerequisite
- Create a Personal Access Token in your Github settings.
- Optionally run a mongodb server to store the data.
Install
$ npm install -g export-github-clones-views
Usage
To simply print the data to console, run the following
$ export-github-clones-views -u <GITHUB_USERNAME> -p <GITHUB_PASSWORD> user/reponame1 organization/reponame2 ...
To store the data to mongodb, provide the mongodb uri,
$ export-github-clones-views -u <GITHUB_USERNAME> -p <GITHUB_PASSWORD> -m <MONGODB_URI> user/reponame1 organization/reponame2 ...
Notes:
- You can add any number of repositories as the argument of the command.
- The repository needs to include both the username/organization and the repository name, e.g.,
hyperjumptech/export-github-clones-views