Skip to content

Commit

Permalink
Merge pull request #2 from billsioros/chore--update-pre-commit-hooks
Browse files Browse the repository at this point in the history
chore: update pre-commit hooks
  • Loading branch information
billsioros authored Jul 23, 2024
2 parents 5fff378 + e7782d7 commit 86a5838
Show file tree
Hide file tree
Showing 2 changed files with 66 additions and 71 deletions.
26 changes: 13 additions & 13 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,17 @@ ci:
autoupdate_commit_msg: 'ci: `pre-commit.ci` auto update'
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.0.269
rev: v0.5.4
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]
- repo: https://github.com/codespell-project/codespell
rev: v2.2.4
rev: v2.3.0
hooks:
- id: codespell
files: \.(py|md)$
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
rev: v4.6.0
hooks:
- id: check-added-large-files
- id: check-ast
Expand All @@ -32,13 +32,13 @@ repos:
- id: check-toml
- id: debug-statements
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.3.0
rev: v1.11.0
hooks:
- id: mypy
files: ^src
additional_dependencies: [types-all]
- repo: https://github.com/commitizen-tools/commitizen
rev: 3.2.2
rev: v3.28.0
hooks:
- id: commitizen
stages: [commit-msg]
Expand All @@ -49,41 +49,41 @@ repos:
stages: [commit-msg]
args: [--ignore=B6, --msg-filename]
- repo: https://github.com/editorconfig-checker/editorconfig-checker.python
rev: 2.7.1
rev: 2.7.3
hooks:
- id: editorconfig-checker
- repo: https://github.com/jendrikseipp/vulture
rev: v2.7
rev: v2.11
hooks:
- id: vulture
- repo: https://github.com/python-jsonschema/check-jsonschema
rev: 0.23.0
rev: 0.29.0
hooks:
- id: check-github-workflows
- id: check-renovate
- repo: https://github.com/PyCQA/docformatter
rev: v1.7.1
rev: v1.7.5
hooks:
- id: docformatter
additional_dependencies: [tomli]
args: [--config, pyproject.toml]
- repo: https://github.com/PyCQA/bandit
rev: 1.7.5
rev: 1.7.9
hooks:
- id: bandit
additional_dependencies: ["bandit[toml]"]
args: ["-c", "pyproject.toml"]
- repo: https://github.com/tox-dev/pyproject-fmt
rev: 0.11.1
rev: 2.1.4
hooks:
- id: pyproject-fmt
args: [--indent, '2']
- repo: https://github.com/google/yamlfmt
rev: v0.9.0
rev: v0.13.0
hooks:
- id: yamlfmt
- repo: https://github.com/python-poetry/poetry
rev: 1.5.0
rev: 1.8.0
hooks:
- id: poetry-check
- id: poetry-lock
Expand Down
111 changes: 53 additions & 58 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,28 +4,16 @@ requires = [
"poetry-core>=1",
]

[tool.mypy]
files = ["src/heartbeat"]
warn_unused_configs = true
warn_return_any = true
ignore_missing_imports = true
pretty = true
color_output = true
show_column_numbers = true
show_error_codes = true
show_error_context = true
strict = true

[tool.poetry]
name = "heartbeat"
version = "0.0.0"
description = "A heart failure detection system"
readme = "README.md"
authors = ["Vassilis Sioros <[email protected]>"]
authors = [ "Vassilis Sioros <[email protected]>" ]
license = "MIT"
homepage = "https://billsioros.github.io/heartbeat"
repository = "https://github.com/billsioros/heartbeat"
keywords = []
keywords = [ ]
classifiers = [
"Programming Language :: Python",
"Programming Language :: Python :: 3",
Expand All @@ -47,6 +35,33 @@ poethepoet = "*"
ruff = "*"

[tool.ruff]
target-version = "py310"

line-length = 99

exclude = [
".bzr",
".direnv",
".eggs",
".git",
".git-rewrite",
".hg",
".mypy_cache",
".nox",
".pants.d",
".pytype",
".ruff_cache",
".svn",
".tox",
".venv",
"__pypackages__",
"_build",
"buck-out",
"build",
"dist",
"node_modules",
"venv",
]
select = [
"A",
"B",
Expand Down Expand Up @@ -93,7 +108,7 @@ select = [
"UP",
"YTT",
]
ignore = []
ignore = [ ]

fixable = [
"A",
Expand Down Expand Up @@ -141,47 +156,34 @@ fixable = [
"UP",
"YTT",
]
unfixable = []
unfixable = [ ]

exclude = [
".bzr",
".direnv",
".eggs",
".git",
".git-rewrite",
".hg",
".mypy_cache",
".nox",
".pants.d",
".pytype",
".ruff_cache",
".svn",
".tox",
".venv",
"__pypackages__",
"_build",
"buck-out",
"build",
"dist",
"node_modules",
"venv",
]
per-file-ignores = {}

line-length = 99

dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"

target-version = "py310"

[tool.ruff.mccabe]
max-complexity = 10
flake8-quotes.docstring-quotes = "double"
mccabe.max-complexity = 10
pydocstyle.convention = "google"

[tool.ruff.pydocstyle]
convention = "google"
[tool.docformatter]
black = true
non-strict = true
non-cap = [ "heartbeat" ]
recursive = true
in-place = true

[tool.ruff.flake8-quotes]
docstring-quotes = "double"
[tool.mypy]
files = [ "src/heartbeat" ]
warn_unused_configs = true
warn_return_any = true
ignore_missing_imports = true
pretty = true
color_output = true
show_column_numbers = true
show_error_codes = true
show_error_context = true
strict = true

[tool.semantic_release]
version_toml = "pyproject.toml:tool.poetry.version"
Expand All @@ -191,7 +193,7 @@ upload_to_pypi = false

[tool.vulture]
min_confidence = 95
paths = ["src/heartbeat"]
paths = [ "src/heartbeat" ]

[tool.poe.tasks]

Expand All @@ -215,13 +217,6 @@ cmd = "poetry run mypy"
help = "Lint your code for errors"
cmd = "poetry run ruff ."

[tool.docformatter]
black = true
non-strict = true
non-cap = ["heartbeat"]
recursive = true
in-place = true

[tool.bandit]
recursive = true
exclude_dirs = ["tests"]
exclude_dirs = [ "tests" ]

0 comments on commit 86a5838

Please sign in to comment.