Releases: pre-commit/pre-commit
Releases · pre-commit/pre-commit
Release list
pre-commit v1.4.1
Fixes
pre-commit autoupdate --repo ...no longer deletes other repos.- #660 issue by @KevinHock.
- #661 PR by @KevinHock.
pre-commit v1.4.0
Features
- Lazily install repositories.
- Version defaulting now applies to local hooks as well.
- Add new
repo: metahooks.metahooks expose some linters of the pre-commit configuration itself.id: check-useless-excludes: ensures thatexcludedirectives actually apply to any file in the repository.id: check-hooks-apply: ensures that the configured hooks apply to at least one file in the repository.- pre-commit/pre-commit-hooks#63 issue by @asottile.
- #405 issue by @asottile.
- #643 PR by @hackedd.
- #653 PR by @asottile.
- #654 PR by @asottile.
- Allow a specific repository to be autoupdated instead of all repositories.
pre-commit autoupdate --repo ...- #656 issue by @KevinHock.
- #657 PR by @KevinHock.
Fixes
- Apply selinux labelling option to docker volumes
- #642 PR by @jimmidyson.
pre-commit v1.3.0
Features
- Add
pre-commit try-repocommands- The new
try-repotakes a repo and will run the hooks configured in that hook repository. - An example invocation:
pre-commit try-repo https://github.com/pre-commit/pre-commit-hooks pre-commit try-repocan also take all the same arguments aspre-commit run.- It can be used to try out a repository without needing to configure it.
- It can also be used to test a hook repository while developing it.
- #589 issue by @sverhagen.
- #633 PR by @asottile.
- The new
pre-commit v1.2.0
Features
- Add
pygreplanguage
Fixes
- Use
pipes.quotefor executable path in hook template - Clean up hook template
- Use
file://protocol for cloning under test - Add
ctypesas an import for virtualenv healthchecks
pre-commit v1.1.2
pre-commit v1.1.1
pre-commit v1.1.0
Features
- pre-commit configuration gains a
fail_fastoption. - pre-commit configuration gains a global
excludeoption.
pre-commit v1.0.1
pre-commit v1.0.0
pre-commit will now be following semver. Thanks to all of the contributors that have helped us get this far!
Features
-
pre-commit's cache directory has moved from
~/.pre-committo$XDG_CACHE_HOME/pre-commit(usually~/.cache/pre-commit). -
A new configuration format for
.pre-commit-config.yamlis introduced which
will enable future development.- The new format has a top-level map instead of a top-level list. The new format puts the hook repositories in a
reposkey. - Old list-based configurations will continue to be supported.
- A command
pre-commit migrate-confighas been introduced to "upgrade" the configuration format to the new map-based configuration. pre-commit autoupdatenow automatically callsmigrate-config.- In a later release, list-based configurations will issue a deprecation warning.
- An example diff for upgrading a configuration:
+repos: - repo: https://github.com/pre-commit/pre-commit-hooks sha: v0.9.2 hooks: - The new format has a top-level map instead of a top-level list. The new format puts the hook repositories in a
Updating
- Run
pre-commit migrate-configto convert.pre-commit-config.yamlto the new map format. - Update any references from
~/.pre-committo~/.cache/pre-commit.