Overview
| Artifact ID: | 8592651ce8ceb218fafa53a1d53fabe5098f1d45dc49809b1aa71d3bfcd8b9be |
|---|---|
| Ticket: | 32709698c64db4c07b07eef89b0c70250fa21118
Language breakdown bar for a repository |
| User & Date: | dmestas on 2026-08-19 13:03:30 |
Changes
- icomment:
Design, now that the About panel (#765689a7ac) gives this a home: **Classification** is by file extension over the tip's tree listing — which is already fetched and memoized per tip, so the raw material is free. Extension → language table for the common few dozen; files that match nothing fall into no bucket rather than "Other" lying about precision. Sizes come from the long listing, so the bar is weighted by BYTES like GitHub's, not file count. **Where it computes:** a memo keyed on the tip hash (the leaves memo pattern) — the answer is immutable per tip, so it is computed once per push, not per render. No index schema change, no fold work: this is a pure derivation over the listing. **Vendored noise:** GitHub uses .gitattributes linguist overrides; our analogue is a `"languages": {"exclude": ["vendor/", "fixtures/"]}` key in `.quarry/repo.json` — same file, same read path as everything else. Defaults to no exclusions; a wrong bar is visible and fixable by commit. **Display:** one stacked bar + the top 6 with percentages, exactly the GitHub shape. Colors from a fixed language→hue table, falling back to branchHue(name) so unknown languages get a stable color for free. - mimetype: "text/x-markdown"