CLI & GUI tool to generate image plate for your GitHub repositories.
- Collect lines of code (LOC) over all repos of a GitHub user:
- private repos are taken into account
- forked repos are NOT taken into account
- The both CLI & GUI variants are available
- Use cache to do not recalculate all the
- It's safe & secure:
- no cloud used
- no token stored
- repos deleted locally after cloned & processed
Pre-built binaries for Windows, Linux, and MacOS are available on Release page.
To get your private token, please follow instructions at https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens. You need to grant the following permissions: Contents - Access: Read-only Metadata - Access: Read-only
The easiest command line you would probably like to go first is the following:
git_stats_plate_gen_cli -u <your_username>
That's it! You'll be securely asked for token then. Once your repos processed, an output image will be generated.
Here is the full list of available options.
Usage: git_stats_plate_gen_cli [OPTIONS]
Options:
-v, --version Print version
-u, --user <name> GitHub username
-t, --token <token> GitHub token (just google 'GitHub Creating a
personal access token'); you need only to grant
access to Repository permissions: Read access to
code, commit statuses, and metadata
-o, --output <filename> Output image filename where the graph will be
written [default:
github_lang_stats-%Y_%m_%d-%H_%M_%S.png]
--cache / --no-cache Use cached data to plot graphics [default: cache]
-mp, --min-percent FLOAT Lower boundary (%) that language must have to be
shown
--help Show this message and exit.
Running the binary without any argument will launch the app if GUI mode. Then, paste your token and press Collect Statistics. NOTE: your GitHub username will be set based on current system account name. Please change it manually if it doesn't match your GitHub account.
Unfortunately, macOS binaries are not signed yet. So you won't be able to launch the binaries. To do so, please refer to this article Open a Mac app from an unidentified developer (https://support.apple.com/en-ke/guide/mac-help/mh40616/mac).
You can run the tool as a regular Python script instead of using pre-built binaries. To do so:
- Clone the repo
- (optional) Create virtual environment & activate it
python -m virtualenv .venv
Windows
.venv\Scripts\activate
Linux/macOS
source .venv/bin/activate
- Install dependencies
python -m pip install -r requirements.txt
- Run binaries:
CLI:
python -m git_stats_plate_gen.cli [options]
GUI:
python -m git_stats_plate_gen.gui
MIT License
Copyright (c) 2023-2024 Pavel Dittenbier
Please refer to License page for details.
Please feel free to contact me: pavel.ditenbir@gmail.com.