Skip to main content

Module classify

Module classify 

Source
Expand description

Which bucket a changed file belongs to, from its path alone. The rule order is the design: Generated outranks Tests so a generated fixture reads as noise, and Build outranks Config so Cargo.toml reads as a manifest.

Rules layers the two things a repo can say for itself over the built-in table: the reader’s own globs, then git’s linguist-* attributes.

Structs§

Rules
The built-in table plus whatever the repo says for itself.

Enums§

Kind
A sidebar bucket. The set is fixed across repos so the reader’s muscle memory carries between them.

Functions§

classify
The built-in table: first match wins.
declared
What a repo declares about a path through the linguist-* git attributes forges already honour, given a reader for one attribute. Vendored code joins Generated: both mean the reader did not write it.