X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=blobdiff_plain;f=.pre-commit-config.yaml;h=7141eeda74e402f6da0129153a6e272935b32609;hb=c8b9acd166fcbd88139a65f7721e522980a0e013;hp=d0d5be76e3d6cb7f79cc54ce708e421e2a5678d9;hpb=3885b944225b4de01cbdf24a88ab103de2841ffe;p=releng%2Fglobal-jjb.git diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index d0d5be76..7141eeda 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -5,8 +5,8 @@ repos: hooks: - id: trailing-whitespace - - repo: https://github.com/prettier/prettier - rev: 2.0.5 + - repo: https://github.com/prettier/pre-commit + rev: v2.1.2 hooks: - id: prettier @@ -16,6 +16,54 @@ repos: - id: gitlint - repo: https://github.com/jumanjihouse/pre-commit-hooks - rev: 2.1.1 + rev: 2.1.5 hooks: - id: shellcheck + + - repo: https://github.com/btford/write-good + rev: v1.0.4 + hooks: + - id: write-good + exclude: > + (?x)^( + docs/jjb/lf-c-cpp-jobs.rst| + docs/jjb/lf-ci-jobs.rst| + docs/jjb/lf-macros.rst| + docs/jjb/lf-python-jobs.rst + )$ + + - repo: https://github.com/btford/write-good + rev: v1.0.4 + hooks: + # Files listed below break the following write-good rules: + # - adverb weakens meaning + # - is wordy or unneeded + # + # This allows us to place an exception need to pass the check without disabling all checks for + # the whole file. + # In an ideal world write-good would give us an override for each individual instance of a + # violation but until then this gives us a close enough approach. + - id: write-good + name: "write-good --no-adverb --no-tooWordy" + args: ["--no-adverb", "--no-tooWordy"] + files: docs/jjb/lf-ci-jobs.rst + + - repo: https://github.com/btford/write-good + rev: v1.0.4 + hooks: + # Files listed below break the following write-good rules: + # - is wordy or unneeded + # + # This allows us to place an exception need to pass the check without disabling all checks for + # the whole file. + # In an ideal world write-good would give us an override for each individual instance of a + # violation but until then this gives us a close enough approach. + - id: write-good + name: "write-good --no-tooWordy" + args: ["--no-tooWordy"] + files: > + (?x)^( + docs/jjb/lf-c-cpp-jobs.rst| + docs/jjb/lf-macros.rst| + docs/jjb/lf-python-jobs.rst + )$