Pre commit hooks
pre-commit hook used to...
Check if the copyright is up to date (using the Git history).
Adding to your .pre-commit-config.yaml
ci:
skip:
# Skip the copyright check on pre-commit.ci because we don't have the Git history
- copyright
- copyright-required
# Poetry didn't works with Python 3.11
- poetry-lock
- poetry-check
repos:
- repo: https://github.com/sbrunner/hooks
rev: <version> # Use the ref you want to point at
hooks:
# Check that the copyright is up to date
- id: copyright
# Check that the copyright is present and up to date
- id: copyright-required
# Require a timeout in GitHub workflow files
- id: workflows-require-timeout
# Check Poetry config
- id: poetry-check
additional_dependencies:
- poetry==<version>
# Do Poetry lock
- id: poetry-lock
additional_dependencies:
- poetry==<version>
# Do Pipfile lock
- id: pipenv-lock
additional_dependencies:
- pipenv==<version>
# Do uv lock, from the pyproject.toml file to the uv.lock file
- id: uv-lock
additional_dependencies:
- uv==<version>
# Export the PEP 751 lock file, from the uv.lock file to the pylock.toml file
- id: uv-pylock
additional_dependencies:
- uv==<version>
# Do Helm lock (helm should be installed)
- id: helm-lock
- id: npm-lock
uv
The uv-lock hook runs uv lock in the folder of the pyproject.toml file and generates the
uv.lock file, the native uv lock format.
The uv-pylock hook runs uv export --format=pylock.toml --output-file=pylock.toml in the folder of
the uv.lock file and generates the pylock.toml file, the PEP 751 lock format.
As with the other lock hooks, the hooks modify the files and pre-commit fails: in the continuous
integration the change is uploaded as the Apply pre-commit fix.patch artifact and applied by the
patch module of ghci, so a dependency bump of the .in file regenerates the .txt file
automatically.
Copyright configuration
The default values used in the .github/copyright.yaml file.
Default values:
one_date_re: ' Copyright \\(c\\) (?P<year>[0-9]{4})"))'
two_date_re: ' Copyright \\(c\\) (?P<from>[0-9]{4})-(?P<to>[0-9]{4})")'
one_date_format: ' Copyright (c) {year}")'
two_date_format: ' Copyright (c) {from}-{to}")'
license_file: LICENSE
one_date_re: ' Copyright \(c\) (?P<year>[0-9]{4})'
two_date_re: ' Copyright \(c\) (?P<from>[0-9]{4})-(?P<to>[0-9]{4})'
one_date_format: ' Copyright (c) {year}'
two_date_format: ' Copyright (c) {from}-{to}'
license_file: LICENSE
Metadata
Release files for sbrunner-hooks 1.9.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| sbrunner_hooks-1.9.0.tar.gz | 9.9 kB | Without provenance | Details for sbrunner_hooks-1.9.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| sbrunner_hooks-1.9.0-py3-none-any.whl | Python 3 | none | any | Details for sbrunner_hooks-1.9.0-py3-none-any.whl |
Total release size: 21.4 kB
Release files / sbrunner_hooks-1.9.0.tar.gz
| Download URL | sbrunner_hooks-1.9.0.tar.gz |
|---|---|
| Size | 9.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
97d7483945c93adbebd62af9eb2d8599d04f356b6c2326d58e41bb465c6a6d94
|
|
BLAKE2b-256 checksum How to use checksums |
8e0deae26f24dc8173c51412fe527830e407054faabbce35ff191067074202bd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.15
|
Release files / sbrunner_hooks-1.9.0-py3-none-any.whl
| Download URL | sbrunner_hooks-1.9.0-py3-none-any.whl |
|---|---|
| Size | 11.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
0c198384a8c4ad97514853528e91bbcc83df5f565809677dd9518063d2aa6801
|
|
BLAKE2b-256 checksum How to use checksums |
3b706901a1bef6b5b9bbd2e7a60fa7a2c606c3dad3c5c65be394681c48c80ac4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.15
|
Security for sbrunner-hooks 1.9.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.