mirror of
https://github.com/Elagoht/githubstatmerge.git
synced 2026-04-26 13:55:56 +03:00
No description
| index.html | ||
| README.md | ||
| screenshot.png | ||
GitMerge — Combined GitHub Contribution Heatmap
A single-file web app that merges contribution data from multiple GitHub accounts into one heatmap. Useful if you have a personal and a work account and want to see your full activity in one view.
Features
- Add up to 6 GitHub accounts, each with its own personal access token
- Per-account tokens means private contributions are included for all accounts
- Merged heatmap shows combined daily contribution counts across all accounts
- Hover any cell for a tooltip with the date, combined total, and per-account breakdown
- Period selector: Last 12 months (rolling window) or a specific year up to 3 years back
- Stats bar shows individual totals and the combined total
- No dependencies, no build step — a single
index.htmlfile
Usage
- Open
index.htmlin any modern browser - Enter a GitHub username and its personal access token, then click +
- Repeat for any additional accounts
- Select a period and click Generate Heatmap
GitHub Token Setup
Each account needs a Personal Access Token with the read:user scope.
- Go to GitHub → Settings → Developer settings → Personal access tokens → Tokens (classic)
- Click Generate new token
- Select the
read:userscope - Copy the token and paste it into the token field next to the username
Without
read:user, the API will only return public contribution data and may omit private repository activity.
How it works
The app queries the GitHub GraphQL API (contributionsCollection) for each account using its own token. Contribution counts are summed per day across all accounts and rendered as a 53-week × 7-day grid (Monday–Sunday), matching GitHub's own contribution graph layout.
GET https://api.github.com/graphql
Authorization: bearer <token>
query {
user(login: "username") {
contributionsCollection(from: "...", to: "...") {
contributionCalendar {
weeks {
contributionDays { date contributionCount }
}
}
}
}
}
Contribution levels
| Color | Count |
|---|---|
| Dark gray | 0 |
| Dark green | 1–3 |
| Medium green | 4–6 |
| Green | 7–9 |
| Bright green | 10+ |
