Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,14 +1,26 @@
default_language_version:
python: python3

# Note: the `exclude` patterns below cover `make gen-project` outputs written
# into linkml_model/ which we do not control. Artefacts copied verbatim from the
# LinkML generators, which emit trailing whitespace and inconsistent final
# newlines (e.g. the bare "// " comment line in protobuf/meta.proto). Native
# sources stay covered: model/schema/, model/docs/, linkml_files.py, etc.

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v6.0.0
hooks:
- id: end-of-file-fixer
exclude: &generated-artefacts |
(?x)^linkml_model/(
(excel|graphql|jsonld|jsonschema|owl|prefixmap|protobuf|rdf|shacl|shex|sqlddl|sqlschema)/
|(annotations|array|datasets|extensions|mappings|meta|types|units|validation)\.py$
Comment thread
amc-corey-cox marked this conversation as resolved.
)
- id: check-yaml
- id: check-toml
- id: trailing-whitespace
exclude: *generated-artefacts

- repo: https://github.com/codespell-project/codespell
rev: v2.4.1
Expand Down
Loading