MCPcopy
hub / github.com/saltstack/salt / spellcheck

Function spellcheck

tools/docs.py:283–304  ·  view source on GitHub ↗
(ctx: Context, no_clean: bool = False, no_color: bool = False)

Source from the content-addressed store, hash-verified

281 },
282)
283def spellcheck(ctx: Context, no_clean: bool = False, no_color: bool = False):
284 if no_clean is False:
285 ctx.run("make", "clean", cwd="doc/", check=True)
286 opts = [
287 "-W",
288 "-j",
289 "auto",
290 "--keep-going",
291 ]
292 if no_color is False:
293 opts.append("--color")
294 ctx.run(
295 "make",
296 "spelling",
297 f"SPHINXOPTS={' '.join(opts)}",
298 cwd="doc/",
299 check=True,
300 )
301 github_output = os.environ.get("GITHUB_OUTPUT")
302 if github_output is not None:
303 with open(github_output, "a", encoding="utf-8") as wfh:
304 wfh.write("has-artifacts=false\n")

Callers

nothing calls this directly

Calls 5

openFunction · 0.50
runMethod · 0.45
appendMethod · 0.45
getMethod · 0.45
writeMethod · 0.45

Tested by

no test coverage detected