Directories
¶
| Path | Synopsis |
|---|---|
|
Package action implements the GitHub Action / CLI entry-point logic for the metrics-cli binary.
|
Package action implements the GitHub Action / CLI entry-point logic for the metrics-cli binary. |
|
Package config holds settings, metadata, and inputs loaders for github-metrics.
|
Package config holds settings, metadata, and inputs loaders for github-metrics. |
|
Package ctxutil provides typed accessors for request-scoped values (currently: the GitHub login the engine is operating on) so that log records and downstream code can correlate work to a single user or organization.
|
Package ctxutil provides typed accessors for request-scoped values (currently: the GitHub login the engine is operating on) so that log records and downstream code can correlate work to a single user or organization. |
|
Package engine wires together the base plugin, the core plugin runner, and the active template into a single Compute call.
|
Package engine wires together the base plugin, the core plugin runner, and the active template into a single Compute call. |
|
Package errors defines the typed error model for the github-metrics project.
|
Package errors defines the typed error model for the github-metrics project. |
|
Package format provides display helpers for rendering numbers, byte counts, percentages, timestamps and error messages.
|
Package format provides display helpers for rendering numbers, byte counts, percentages, timestamps and error messages. |
|
Package githubapi wraps GitHub REST and GraphQL access, the rate tracker, and the MOCKED_TOKEN safety guard.
|
Package githubapi wraps GitHub REST and GraphQL access, the rate tracker, and the MOCKED_TOKEN safety guard. |
|
Package httpx wraps net/http with retry, structured logging, and the User-Agent string the project uses for every outbound request.
|
Package httpx wraps net/http with retry, structured logging, and the User-Agent string the project uses for every outbound request. |
|
Package logger configures a slog logger for the github-metrics project.
|
Package logger configures a slog logger for the github-metrics project. |
|
Package plugins defines the plugin contract that every github-metrics data source implements, together with the in-memory Data structure the engine builds up as it executes plugins.
|
Package plugins defines the plugin contract that every github-metrics data source implements, together with the in-memory Data structure the engine builds up as it executes plugins. |
|
achievements
Package achievements owns the M4 "achievements" plugin.
|
Package achievements owns the M4 "achievements" plugin. |
|
activity
Package activity owns the M4 "activity" plugin.
|
Package activity owns the M4 "activity" plugin. |
|
base
Package base owns the special "base" plugin: it runs before every other plugin and populates the shared Data.User / Data.Organization / Data.Computed fields that downstream plugins depend on.
|
Package base owns the special "base" plugin: it runs before every other plugin and populates the shared Data.User / Data.Organization / Data.Computed fields that downstream plugins depend on. |
|
calendar
Package calendar owns the M4 "calendar" plugin.
|
Package calendar owns the M4 "calendar" plugin. |
|
contributors
Package contributors owns the M4 "contributors" plugin.
|
Package contributors owns the M4 "contributors" plugin. |
|
core
Package core hosts the special "core" plugin.
|
Package core hosts the special "core" plugin. |
|
habits
Package habits owns the M4 "habits" plugin.
|
Package habits owns the M4 "habits" plugin. |
|
isocalendar
Package isocalendar owns the M4 "isocalendar" plugin.
|
Package isocalendar owns the M4 "isocalendar" plugin. |
|
languages
Package languages — indepth.go implements the "languages.indepth" sub-mode of the M4 languages plugin.
|
Package languages — indepth.go implements the "languages.indepth" sub-mode of the M4 languages plugin. |
|
notable
Package notable owns the M4 "notable" plugin.
|
Package notable owns the M4 "notable" plugin. |
|
people
Package people owns the M4 "people" plugin.
|
Package people owns the M4 "people" plugin. |
|
pluginutil
Package pluginutil collects the small input-parsing and formatting helpers that nearly every plugin reimplements verbatim.
|
Package pluginutil collects the small input-parsing and formatting helpers that nearly every plugin reimplements verbatim. |
|
projects
Package projects owns the M4 "projects" plugin.
|
Package projects owns the M4 "projects" plugin. |
|
reactions
Package reactions owns the M4 "reactions" plugin.
|
Package reactions owns the M4 "reactions" plugin. |
|
repositories
Package repositories owns the M4 "repositories" plugin.
|
Package repositories owns the M4 "repositories" plugin. |
|
sponsors
Package sponsors owns the M4 "sponsors" plugin.
|
Package sponsors owns the M4 "sponsors" plugin. |
|
sponsorships
Package sponsorships owns the M4 "sponsorships" plugin.
|
Package sponsorships owns the M4 "sponsorships" plugin. |
|
stargazers
Package stargazers owns the M4 "stargazers" plugin.
|
Package stargazers owns the M4 "stargazers" plugin. |
|
starlists
Package starlists owns the M4 "starlists" plugin.
|
Package starlists owns the M4 "starlists" plugin. |
|
stars
Package stars owns the M4 "stars" plugin.
|
Package stars owns the M4 "stars" plugin. |
|
topics
Package topics owns the M4 "topics" plugin.
|
Package topics owns the M4 "topics" plugin. |
|
traffic
Package traffic owns the M4 "traffic" plugin.
|
Package traffic owns the M4 "traffic" plugin. |
|
Package render implements the chromedp-backed SVG resize, the pure-Go svg.Hash, the SVG decoration pipeline (octicon / CSS purge / XML format), and the small Renderer interface that engine.Compute consumes.
|
Package render implements the chromedp-backed SVG resize, the pure-Go svg.Hash, the SVG decoration pipeline (octicon / CSS purge / XML format), and the small Renderer interface that engine.Compute consumes. |
|
Package templates defines the Template contract used by the engine to render a request into one of the supported output formats.
|
Package templates defines the Template contract used by the engine to render a request into one of the supported output formats. |
|
chrome
Package chrome owns the rendering bits both templates share — the metadata footer, the BaseHeader mini-contribution row, the `base` section resolver, and the lazy CSS asset loader.
|
Package chrome owns the rendering bits both templates share — the metadata footer, the BaseHeader mini-contribution row, the `base` section resolver, and the lazy CSS asset loader. |
|
classic
Package classic implements the M2 "classic" template — the default upstream GitHub-visual-identity SVG layout.
|
Package classic implements the M2 "classic" template — the default upstream GitHub-visual-identity SVG layout. |
|
classic/partials
Package partials hosts the partial functions assembled by the classic template.
|
Package partials hosts the partial functions assembled by the classic template. |
|
repository
Package repository implements the M7 "repository" template — the upstream-equivalent SVG layout focused on a single repository instead of a user profile.
|
Package repository implements the M7 "repository" template — the upstream-equivalent SVG layout focused on a single repository instead of a user profile. |
|
repository/partials
Package partials hosts the repository-template-specific partials the M7 layout needs.
|
Package partials hosts the repository-template-specific partials the M7 layout needs. |
|
Package testutil hosts the shared test infrastructure landed in M9.
|
Package testutil hosts the shared test infrastructure landed in M9. |
|
golden
Package golden hosts the M9 unified golden-file workflow: Compare / CompareSVG / CompareJSON sharing the `-update` flag declared in tests/integration/output_json_test.go.
|
Package golden hosts the M9 unified golden-file workflow: Compare / CompareSVG / CompareJSON sharing the `-update` flag declared in tests/integration/output_json_test.go. |
|
mocks
Package mocks hosts the M9 shared mock RoundTrippers + PluginContext builder consumed by `*_test.go` files across the project.
|
Package mocks hosts the M9 shared mock RoundTrippers + PluginContext builder consumed by `*_test.go` files across the project. |
|
svgcontent
Package svgcontent extracts the *semantic* (visible / structural) content of a rendered metrics SVG so tests can assert on what a viewer actually sees — not on byte equality or pixel height.
|
Package svgcontent extracts the *semantic* (visible / structural) content of a rendered metrics SVG so tests can assert on what a viewer actually sees — not on byte equality or pixel height. |
|
tools
|
|
|
check-compat
command
Command check-compat diffs the input-key sets between the upstream lowlighter/metrics checkout (./org_repo) and the vendored copy under assets/.
|
Command check-compat diffs the input-key sets between the upstream lowlighter/metrics checkout (./org_repo) and the vendored copy under assets/. |
|
gen-action-yml
command
Command gen-action-yml generates the project's action.yml from the embedded plugin / template metadata.yml files + core input definitions.
|
Command gen-action-yml generates the project's action.yml from the embedded plugin / template metadata.yml files + core input definitions. |
|
gen-graphql
command
Command gen-graphql wraps genqlient's code generator so it picks up the project's pinned dependency versions (notably the modern golang.org/x/tools required by Go 1.26+) instead of whatever transient versions `go run github.com/Khan/genqlient` would resolve to.
|
Command gen-graphql wraps genqlient's code generator so it picks up the project's pinned dependency versions (notably the modern golang.org/x/tools required by Go 1.26+) instead of whatever transient versions `go run github.com/Khan/genqlient` would resolve to. |
|
gen-octicons
command
Command gen-octicons reads the @primer/octicons build/data.json shipped by the npm package and writes a trimmed, embed-friendly assets/octicons/data.json that internal/render.ReplaceOcticons consumes at runtime.
|
Command gen-octicons reads the @primer/octicons build/data.json shipped by the npm package and writes a trimmed, embed-friendly assets/octicons/data.json that internal/render.ReplaceOcticons consumes at runtime. |
|
gen-plugin-docs
command
Command gen-plugin-docs emits per-plugin markdown pages under docs/plugins/ and refreshes the plugins-gallery AUTOGEN block inside README.md.
|
Command gen-plugin-docs emits per-plugin markdown pages under docs/plugins/ and refreshes the plugins-gallery AUTOGEN block inside README.md. |
|
record-fixtures
command
Command record-fixtures captures real GitHub GraphQL responses for a fixed set of accounts/repos and vendors them under tests/fixtures/ as replay fixtures for the layer-2 data tests.
|
Command record-fixtures captures real GitHub GraphQL responses for a fixed set of accounts/repos and vendors them under tests/fixtures/ as replay fixtures for the layer-2 data tests. |
|
svg2png
command
Command svg2png rasterizes one or more standalone metrics SVG files to PNG using the same chromedp-based renderer the production pipeline uses (internal/render.Browser + Resize).
|
Command svg2png rasterizes one or more standalone metrics SVG files to PNG using the same chromedp-based renderer the production pipeline uses (internal/render.Browser + Resize). |
|
sync-fixtures
command
Command sync-fixtures captures the upstream lowlighter/metrics output for a given test case (e.g.
|
Command sync-fixtures captures the upstream lowlighter/metrics output for a given test case (e.g. |
Click to show internal directories.
Click to hide internal directories.