Skip to content

Commit

Permalink
Bump pre-commit hooks
Browse files Browse the repository at this point in the history
  • Loading branch information
domdfcoding committed Jan 31, 2024
1 parent a25c821 commit ac9176c
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
14 changes: 7 additions & 7 deletions repo_helper/files/pre_commit.py
Original file line number Diff line number Diff line change
Expand Up @@ -193,19 +193,19 @@ def to_dict(self) -> MutableMapping[str, Union[str, List[Hook]]]:

lucas_c_hooks = Repo(
repo=make_github_url("Lucas-C", "pre-commit-hooks"),
rev="v1.5.1",
rev="v1.5.4",
hooks=["remove-crlf", "forbid-crlf"],
)

flake2lint = Repo(
repo=make_github_url("domdfcoding", "flake2lint"),
rev="v0.4.2",
rev="v0.4.3",
hooks=["flake2lint"],
)

pyproject_parser = Repo(
repo=make_github_url("repo-helper", "pyproject-parser"),
rev="v0.9.0",
rev="v0.9.1",
hooks=["reformat-pyproject"], # TODO: add check-pyproject
)

Expand Down Expand Up @@ -257,7 +257,7 @@ def make_pre_commit(repo_path: pathlib.Path, templates: Environment) -> List[str

flake8_dunder_all = Repo(
repo=make_github_url("domdfcoding", "flake8-dunder-all"),
rev="v0.3.0",
rev="v0.3.1",
hooks=[{
"id": "ensure-dunder-all",
"files": fr"^{import_name}{'-stubs' if stubs_package else ''}/.*\.py$"
Expand All @@ -266,15 +266,15 @@ def make_pre_commit(repo_path: pathlib.Path, templates: Environment) -> List[str

snippet_fmt = Repo(
repo=make_github_url("python-formate", "snippet-fmt"),
rev="v0.1.4",
rev="v0.1.5",
hooks=["snippet-fmt"],
)

formate_excludes = fr"^({'|'.join([*templates.globals['yapf_exclude'], *non_source_files])})\.(_)?py$"

formate = Repo(
repo=make_github_url("python-formate", "formate"),
rev="v0.5.0",
rev="v0.7.0",
hooks=[{"id": "formate", "exclude": formate_excludes}],
)

Expand All @@ -290,7 +290,7 @@ def make_pre_commit(repo_path: pathlib.Path, templates: Environment) -> List[str

dep_checker = Repo(
repo=make_github_url("domdfcoding", "dep_checker"),
rev="v0.7.1",
rev="v0.8.0",
hooks=[{"id": "dep_checker", "args": dep_checker_args}]
)

Expand Down
14 changes: 7 additions & 7 deletions tests/test_files/test_testing_/test_make_pre_commit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ ci:

repos:
- repo: https://github.com/repo-helper/pyproject-parser
rev: v0.9.0
rev: v0.9.1
hooks:
- id: reformat-pyproject

Expand Down Expand Up @@ -43,13 +43,13 @@ repos:
- id: bind-requirements

- repo: https://github.com/domdfcoding/flake8-dunder-all
rev: v0.3.0
rev: v0.3.1
hooks:
- id: ensure-dunder-all
files: ^hello_world/.*\.py$

- repo: https://github.com/domdfcoding/flake2lint
rev: v0.4.2
rev: v0.4.3
hooks:
- id: flake2lint

Expand All @@ -70,24 +70,24 @@ repos:
- --keep-runtime-typing

- repo: https://github.com/Lucas-C/pre-commit-hooks
rev: v1.5.1
rev: v1.5.4
hooks:
- id: remove-crlf
- id: forbid-crlf

- repo: https://github.com/python-formate/snippet-fmt
rev: v0.1.4
rev: v0.1.5
hooks:
- id: snippet-fmt

- repo: https://github.com/python-formate/formate
rev: v0.5.0
rev: v0.7.0
hooks:
- id: formate
exclude: ^(doc-source/conf|__pkginfo__|setup)\.(_)?py$

- repo: https://github.com/domdfcoding/dep_checker
rev: v0.7.1
rev: v0.8.0
hooks:
- id: dep_checker
args:
Expand Down

0 comments on commit ac9176c

Please sign in to comment.