Use pre-commit.ci
to automatically update pre-commit hook versions
#665
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
pre-commit hooks are running (very) old versions, and need to be updated.
To update pre-commit hook versions, we can manually run this command
Alternatively, we can use
pre-commit.ci
to automate the update. This will automatically create PRs to update the hook versions. For example, see fastapi/fastapi#9259Pre-comit.ci is free for open source repositories
Source
https://chrisholdgraf.com/blog/2022/precommit-autoupdate/
https://pre-commit.ci/
Reference
https://github.com/tiangolo/fastapi/blob/1d41a7d2df5714e6598b541cac3cac5859b3ad4b/.pre-commit-config.yaml#L23