1- ci :
2- # Defer autoupdate to quarterly (there is no 'off' button) to have renovate pick up first
3- autoupdate_schedule : quarterly
4- skip : [setup, setup_test, pylint, markdownlint, testing, biome]
5- submodules : true
6-
71default_language_version :
82 # force all unspecified python hooks to run python3
93 python : python3.13
@@ -14,31 +8,39 @@ repos:
148 rev : v0.8.2
159 hooks :
1610 - id : ruff
11+ name : " Ruff check"
1712 args :
1813 - --fix
14+ - id : ruff-format
15+ name : " Ruff format"
1916 - repo : https://github.com/pre-commit/pre-commit-hooks
2017 rev : v5.0.0
2118 hooks :
2219 - id : check-executables-have-shebangs
20+ name : " Check scripts"
2321 stages : [manual]
2422 - id : no-commit-to-branch
23+ name : " Check branch"
2524 args :
2625 - --branch=main
2726 - repo : https://github.com/asottile/pyupgrade
2827 rev : v3.19.0
2928 hooks :
3029 - id : pyupgrade
31- args : [--py39-plus]
30+ name : " Check Py upgrade"
31+ args : [--py311-plus]
3232 # Moved codespell configuration to setup.cfg as per 'all-files' issues not reading args
3333 - repo : https://github.com/codespell-project/codespell
3434 rev : v2.3.0
3535 hooks :
3636 - id : codespell
37+ name : " Check spelling"
3738 exclude_types : [csv, json]
3839 - repo : https://github.com/PyCQA/bandit
3940 rev : 1.8.0
4041 hooks :
4142 - id : bandit
43+ name : " Bandit checking"
4244 args :
4345 - --quiet
4446 - --format=custom
@@ -48,13 +50,15 @@ repos:
4850 rev : v1.35.1
4951 hooks :
5052 - id : yamllint
53+ name : " YAML linting"
5154 - repo : https://github.com/cdce8p/python-typing-update
5255 rev : v0.7.0
5356 hooks :
5457 # Run `python-typing-update` hook manually from time to time
5558 # to update python typing syntax.
5659 # Will require manual work, before submitting changes!
5760 - id : python-typing-update
61+ name : " Python typing"
5862 stages : [manual]
5963 args :
6064 - --py39-plus
@@ -68,41 +72,41 @@ repos:
6872 # committing from a GUI tool that was not launched from an activated
6973 # shell.
7074 - id : setup
71- name : Setup python
75+ name : " Setup"
7276 entry : /usr/bin/env bash -c 'test -d ./venv || scripts/setup.sh'
7377 language : script
7478 - id : setup_test
75- name : Setup testing
79+ name : " Setup (extended for testing"
7680 entry : /usr/bin/env bash -c 'test -f ./tmp/biome || scripts/setup_test.sh pre-commit'
7781 language : script
7882 - id : userdata
79- name : userdata
83+ name : " Validating userdata"
8084 entry : scripts/pre-commit.sh
8185 language : script
8286 types : [python]
8387 pass_filenames : false
8488 - id : mypy
85- name : mypy
89+ name : " Running MyPy "
8690 entry : scripts/run-in-env.sh mypy
8791 language : script
8892 types : [python]
8993 require_serial : true
9094 files : ^plugwise/$
9195 - id : pylint
92- name : pylint
96+ name : " PyLinting "
9397 entry : scripts/run-in-env.sh pylint -j 0
9498 language : script
9599 types : [python]
96100 files : ^plugwise/.+\.py$
97101 - id : testing
98- name : " Local Testing - Performing Tests"
102+ name : " Performing Tests"
99103 # yamllint disable-line rule:line-length
100- entry : /usr/bin/env bash -c 'exec env GITHUB_ACTIONS="1" scripts/tests_and_coverage.sh test_and_coverage'
104+ entry : /usr/bin/env bash -c 'exec env GITHUB_ACTIONS="1" NO_FIXTURES="1" scripts/tests_and_coverage.sh test_and_coverage'
101105 language : script
102106 pass_filenames : false
103107 - id : biome
104- name : " Local Linting - Biome"
105- entry : ./tmp/biome lint --staged --files-ignore-unknown=true --no-errors-on-unmatched
108+ name : " Biome (prettier) "
109+ entry : ./tmp/biome check fixtures/ plugwise/ tests/ --files-ignore-unknown=true --no-errors-on-unmatched --json-formatter-indent-width=2 --json-formatter-indent-style=space
106110 language : script
107111 - repo : https://github.com/igorshubovych/markdownlint-cli
108112 rev : v0.43.0
0 commit comments