Skip to main content

Crate sloc_config

Crate sloc_config 

Source

Structs§

AnalysisConfig
AppConfig
BudgetConfig
Per-language and total SLOC thresholds. Used with --fail-on-budget in CI.
DiscoveryConfig
GitConfig
Non-secret git integration settings. Per-host credentials are intentionally NOT here — tokens/keys live only in the environment (SLOC_GIT_CRED_<HOST>, SLOC_GIT_SSHKEY_<HOST>) or the SLOC_GIT_CRED_FILE, never in a committed TOML. This section only carries the offline-import gate so operators who prefer a config file over env vars can set it there. Values here are applied to the environment at startup only if the corresponding env var is unset, so an explicit env var always wins (see AppConfig::apply_git_settings_to_env).
ProfileConfig
A named configuration profile.
ReportingConfig
WebConfig

Enums§

BinaryFileBehavior
BlankInBlockCommentPolicy
IEEE 1045-1992: how blank lines that fall inside a block comment are classified.
ContinuationLinePolicy
IEEE 1045-1992: how backslash line continuations are handled for physical SLOC counting.
FailureBehavior
MixedLinePolicy

Functions§

validate_hex_color
Validates that s is a CSS hex colour: #RGB or #RRGGBB.