gm-assistant/.pre-commit-config.yaml

32 lines
917 B
YAML

# SPDX-FileCopyrightText: 2025 2025
# SPDX-FileContributor: Gergely Polonkai
#
# SPDX-License-Identifier: GPL-3.0-or-later
repos:
- repo: local
hooks:
- id: commitizen
name: commitizen check
stages: ["commit-msg"]
language: system
entry: poetry run cz
args: ["check", "--allow-abort", "--commit-msg-file"]
- id: commitizen-branch
name: commitizen check branch
stages: [pre-push]
language: system
always_run: true
entry: poetry run cz
args: ["check", "--rev-range", "origin/HEAD..HEAD"]
pass_filenames: false
- id: black
name: black
description: "Black: The uncompromising Python code formatter"
stages: ["pre-commit"]
language: system
entry: poetry run black
args: ["--check", "--diff"]
require_serial: true
types_or: [python, pyi]