mirror of
https://github.com/ansible-collections/hetzner.hcloud.git
synced 2026-02-04 08:01:49 +00:00
chore: setup pre-commit (#234)
* chore: add pre-commit config * chore: fix pre-commit errors * chore: add black pre-commit hook * style: format python files with black * chore: add isort pre-commit hook * style: format python files using isort * chore: add pyupgrade pre-commit hook * refactor: upgrade code to python3.7 * Allow stacking PRs Co-authored-by: Julian Tölle <julian.toelle97@gmail.com> --------- Co-authored-by: Julian Tölle <julian.toelle97@gmail.com>
This commit is contained in:
parent
e83997517d
commit
dfff49e31f
42 changed files with 904 additions and 1091 deletions
|
|
@ -1,4 +1,5 @@
|
|||
stages:
|
||||
- lint
|
||||
- sanity
|
||||
- integration
|
||||
|
||||
|
|
@ -8,6 +9,16 @@ variables:
|
|||
default:
|
||||
image: python:$PYTHON_VERSION
|
||||
|
||||
pre-commit:
|
||||
stage: lint
|
||||
|
||||
image: python:3.11-alpine
|
||||
before_script:
|
||||
- apk add build-base git
|
||||
- pip install pre-commit
|
||||
script:
|
||||
- pre-commit run --all-files --show-diff-on-failure
|
||||
|
||||
sanity:
|
||||
stage: sanity
|
||||
allow_failure: true
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue