Skip to content

About

Automated GitHub analytics dashboard with daily updates via GitHub Actions

Topics

Resources

Stars

13 stars

Watchers

0 watching

Forks

Latest commit

 

History

34 Commits

Folders and files

Repository files navigation

GitHub Analytics

A dashboard of your GitHub repos, drawn as an SVG for your profile README. A GitHub Action fetches your repos every night, draws the picture and commits it, so the image above is always about a day old. Only repos you own count, and forks are left out.

Layouts

Three layouts, picked with DASHBOARD_LAYOUT. Each has a default theme.

card layout
card
Default · 1200 × 660 · theme redline
Four KPI tiles with sparklines, the top languages, lifecycle and the three most starred repos.
bento layout
bento
1200 × 840 · theme mono
A grid of tiles: languages with stars and live counts, a live ring, one square per repo, repos per month, a leaderboard.
terminal layout
terminal
1200 × 700 · theme phosphor
The same numbers as command output, with block-character bars and a last-push heatmap.
card layout without gradients
card with DASHBOARD_GRADIENTS=0
1200 × 600
The flat look: solid bars, no sparklines. Applies to card and bento; terminal has no gradients.

Themes

Twelve themes, picked with DASHBOARD_THEME. Any theme works with any layout; here they are on the card.

frost
frost
Cool slate, ice-blue lead, mint for Live.
mono
mono
Black to grey to white, no hue.
phosphor
phosphor
CRT green with amber and cyan.
graphite
graphite
Neutral black, lime lead.
dusk
dusk
Deep plum, coral lead.
daylight
daylight
Light mode.
divergence
divergence
Amber and auburn, warm and high contrast.
lab
lab
Petrol base with green, amber and auburn.
github
github
GitHub's own dark palette.
worldline
worldline
Red terminal with nixie-tube amber, after the Steins;Gate divergence meter.
edgerunner
edgerunner
Yellow, magenta and cyan on deep blue, sampled from Cyberpunk: Edgerunners.
redline
redline
The Edgerunners netrunning HUD: coral red on dark teal, green for Live.

The layout and theme pictures are a snapshot, made with python scripts/readme_previews.py. Only the dashboard at the top updates every night.

Make it yours

To Change
Pick the layout, theme or flat look Repository variables DASHBOARD_LAYOUT, DASHBOARD_THEME, DASHBOARD_GRADIENTS (Settings → Secrets and variables → Actions → Variables), or from a terminal: gh variable set DASHBOARD_LAYOUT --body bento, gh variable set DASHBOARD_THEME --body dusk, then gh workflow run update-dashboard.yml to redraw now. An empty theme means the layout's default.
List more or fewer languages TOP_N in assets/layouts/common.py. Colors repeat after 5. The card fits about 10 rows, bento and terminal about 7.
Exclude or include languages FILTERED_LANGS in assets/layouts/common.py. HTML, CSS and JavaScript are left out by default because they are usually a side effect of a repo, not what it is written in.
Show private repos in the leaderboards SHOW_PRIVATE = True in assets/layouts/common.py. Their names then appear in the public SVG.
Count forks Remove the fork filter in src/transform.py.
Mark a repo's status Add one topic to the repo on GitHub: wip, paused, finished or dropped. No code change.
Change the status topics STATUS_TOPICS in src/transform.py.
Add a theme Copy a block in src/palettes.py and change the colors. track, prog and stub are optional.
Change the update time The cron line in .github/workflows/update-dashboard.yml (daily at 00:00 UTC).

How the numbers work

  • Lifecycle comes from a status topic you set on each repo: wip is In progress, paused is Paused, finished is Finished, dropped is Dropped. Untagged repos still count in the totals but stay out of the lifecycle charts.
  • Live repos counts every repo pushed in the last 90 days, whatever its tag.
  • Only repos you own are counted: no forks, no organization or collaborator repos.
  • Top languages: repos with no language or a filtered one are dropped, the rest are counted per language and sorted by count, then total stars, then name, so ties always land in the same order. Everything past TOP_N goes into "Other". Percentages are of the counted repos, rounded, so they may not add up to exactly 100.
  • Last push by month counts repos by the month of their latest push, which is not the same as commit activity.
  • Counts include private repos; names don't. The CSV the pipeline writes (data/github_repos_clean.csv) has every repo name, so it stays on your machine and out of git.

Set it up

  1. Fork or clone this repo and keep it public.
  2. Add a repository secret GH_TOKEN: a personal access token with repo scope (needed to count private repos).
  3. Enable Actions, then run "Update GitHub Analytics Dashboard" once from the Actions tab.
  4. Add the image to your profile README:
![GitHub Analytics](https://raw.githubusercontent.com/YOUR_USERNAME/REPO_NAME/main/data/github_dashboard.svg)

To run it locally, you need Python 3.11+ and a .env with GITHUB_TOKEN:

python -m venv .venv
source .venv/bin/activate        # Windows: .venv\Scripts\activate
pip install -r requirements.txt
DASHBOARD_LAYOUT=bento python src/main.py
python tests/smoke_test.py       # renders every layout and theme from a fixed dataset

Licence

MIT. The dashboard uses the Inter, Space Grotesk and JetBrains Mono fonts, under the SIL Open Font License 1.1 (licence files in assets/fonts/).

About

Automated GitHub analytics dashboard with daily updates via GitHub Actions

Topics

Resources

Stars

13 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages