From a98faa91697d28f5e03ebda82be0eee7795be86e Mon Sep 17 00:00:00 2001 From: pedro-fuoco Date: Sat, 8 Jul 2023 13:51:34 -0300 Subject: [PATCH] Tools: Add pre-commit with black and xmllint --- .pre-commit-config.yaml | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 .pre-commit-config.yaml diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 0000000..57402d1 --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,23 @@ +repos: + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v4.2.0 + hooks: + - id: trailing-whitespace + - id: end-of-file-fixer + - id: mixed-line-ending + name: Check line ending character (LF) + args: ["--fix=lf"] + - id: check-added-large-files + - id: check-merge-conflict + - id: check-xml + - id: check-yaml + + - repo: https://github.com/lsst-ts/pre-commit-xmllint + rev: v1.0.0 + hooks: + - id: format-xmllint + + - repo: https://github.com/psf/black + rev: 23.1.0 + hooks: + - id: black