zuke.tools.cspell
@zuke/cspell 1.2.0: @zuke/cspell — typed cspell task wrappers for Zuke builds.
zuke on PyPI ↗ 2 symbols
Symbols
class CspellSettings(ToolSettings) Settings for a cspell lint run.
-
files(*globs: str) -> SelfFiles or globs to check (positional); repeatable.
-
config(path: str) -> SelfUse an explicit config file (
-c/--config). -
no_progress() -> SelfSuppress the progress output (
--no-progress). -
no_summary() -> SelfSuppress the summary line (
--no-summary). -
show_suggestions() -> SelfPrint spelling suggestions for each issue (
--show-suggestions). -
show_context() -> SelfPrint the surrounding line for each issue (
--show-context). -
quiet_output() -> SelfOnly emit issues, hiding informational output (
--quiet). -
cache() -> SelfCache results between runs (
--cache). -
dot() -> SelfInclude dotfiles and dot-directories (
--dot). -
gitignore() -> SelfHonour
.gitignorefiles (--gitignore). -
gitignore_root(path: str) -> SelfStop the
.gitignoresearch at this directory (--gitignore-root). Without it cspell keeps walking up past the repository root and can pick up an unrelated.gitignorefrom a parent directory — so a run inside a git worktree, whose checkout lives outside the main working tree, sees ignore rules that do not belong to it. Point this at the repository root to bound the search. -
no_must_find_files() -> SelfExit successfully when a glob matches nothing (
--no-must-find-files). cspell fails by default if any file argument matched no files. A run scoped to a computed file list — the staged files, the files a diff touched — can legitimately be empty, so a file-scoped run wants this. -
unique() -> SelfReport each unique issue only once (
--unique). -
locale(value: str) -> SelfRestrict to a locale, e.g.
en,en-GB(--locale). -
exclude(glob: str) -> SelfExclude files matching a glob (
-e/--exclude); repeatable. -
max_duplicate_problems(count: float) -> SelfCap the number of duplicate problems reported (
--max-duplicate-problems).
class CspellTasks Typed task functions for the cspell spell-checker.
-
static async lint(ctx: ServiceContext, configure: Callable[[CspellSettings], CspellSettings] | None=None) -> ExecResultSpell-check with
cspell lint.