From eeb1158e8bec2d5192f8ccf295141e94aa4f0506 Mon Sep 17 00:00:00 2001 From: Sharpz7 Date: Fri, 26 Jan 2024 05:06:32 +0000 Subject: [PATCH] [codespell] Adding Tox Target for Codespell Second in a series of commits to add Codespell to Ironic Repos. This one adds the command that was used to fix the spelling errors. Future Commits will add CI support and potentially a git-blame-ignore-revs file if their are lots of spelling mistakes that could clutter git blame. Change-Id: Ib439c9873d601bb140bd3f97acb5ee2d551c7063 --- setup.cfg | 5 +++++ tox.ini | 9 +++++++++ 2 files changed, 14 insertions(+) diff --git a/setup.cfg b/setup.cfg index 785b7c39..87728dcc 100644 --- a/setup.cfg +++ b/setup.cfg @@ -29,3 +29,8 @@ packages = [entry_points] sushy.resources.system.oems = contoso = sushy.resources.oem.fake:get_extension + +[codespell] +quiet-level = 4 +# Words to ignore: +# ignore-words-list = example \ No newline at end of file diff --git a/tox.ini b/tox.ini index e22391a9..2aeae19f 100644 --- a/tox.ini +++ b/tox.ini @@ -87,3 +87,12 @@ exclude=.*,dist,doc,*lib/python*,*egg,build import-order-style = pep8 application-import-names = sushy filename = *.py + +[testenv:codespell] +description = + Run codespell to check spelling +deps = codespell +# note(JayF): {posargs} lets us run `tox -ecodespell -- -w` to get codespell +# to correct spelling issues in our code it's aware of. +commands = + codespell {posargs} \ No newline at end of file