From 8aaa22683099477dc9bf30af4a505de2ef0ffba3 Mon Sep 17 00:00:00 2001 From: Andrew Imeson Date: Wed, 22 Mar 2023 05:31:20 -0400 Subject: [PATCH] docs: Update pre-commit hook example Update syntax of pre-commit hook docs to work with newer pre-commit versions. Closes #551, #553 --- docs/integration.rst | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/docs/integration.rst b/docs/integration.rst index 0a00e11..9a6a935 100644 --- a/docs/integration.rst +++ b/docs/integration.rst @@ -4,7 +4,7 @@ Integration with other software Integration with pre-commit --------------------------- -You can integrate yamllint in `pre-commit `_ tool. +You can integrate yamllint in the `pre-commit `_ tool. Here is an example, to add in your .pre-commit-config.yaml .. code:: yaml @@ -12,11 +12,13 @@ Here is an example, to add in your .pre-commit-config.yaml --- # Update the rev variable with the release version that you want, from the yamllint repo # You can pass your custom .yamllint with args attribute. - - repo: https://github.com/adrienverge/yamllint.git - rev: v1.17.0 - hooks: - - id: yamllint - args: [-c=/path/to/.yamllint] + repos: + - repo: https://github.com/adrienverge/yamllint.git + rev: v1.29.0 + hooks: + - id: yamllint + args: [--strict, -c=/path/to/.yamllint] + Integration with GitHub Actions -------------------------------