Pre commit hook by sbrunner
Project description
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 Helm lock (helm should be installed)
- id: helm-lock
Copyright configuration
The default values used in the .github/copyright.yaml
file.
Default values:
one_date_re: ' Copyright \\(c\\) (?P<year>[0-9]{4})"))'
tow_date_re: ' Copyright \\(c\\) (?P<from>[0-9]{4})-(?P<to>[0-9]{4})")'
one_date_format: ' Copyright (c) {year}")'
tow_date_format: ' Copyright (c) {from}-{to}")'
license_file: LICENSE
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
sbrunner_hooks-0.5.0.tar.gz
(5.0 kB
view hashes)
Built Distribution
Close
Hashes for sbrunner_hooks-0.5.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3fa311202410bb3f9b61911e1de96e951384de6244d1a07ccbb05227e6c424b1 |
|
MD5 | 50424cc060d2e4699c3cb993d033e8a5 |
|
BLAKE2b-256 | b39e036180af88322f09ba6f4af855fc6b3f85720232e715094812134bc42d55 |