Skip to content

Commit

Permalink
pylint to ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
jnewb1 committed Aug 7, 2023
1 parent ba3238e commit f92faca
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 18 deletions.
20 changes: 3 additions & 17 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,24 +8,10 @@ repos:
rev: v1.4.1
hooks:
- id: mypy
- repo: https://github.com/PyCQA/flake8
rev: 6.1.0
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.0.282
hooks:
- id: flake8
args:
- --select=F,E112,E113,E304,E501,E502,E701,E702,E703,E71,E72,E731,W191,W6
- --max-line-length=240
- --statistics
- repo: local
hooks:
- id: pylint
name: pylint
entry: pylint
language: system
types: [python]
exclude: 'site_scons/'
args:
- --disable=C,R,W0613,W0511,W0212,W0201,W0311,W0106,W0603,W0621,W0703,E1136
- id: ruff
- repo: local
hooks:
- id: cppcheck
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ ENV PATH="/root/.pyenv/bin:/root/.pyenv/shims:${PATH}"
RUN pyenv install 3.11.4 && \
pyenv global 3.11.4 && \
pyenv rehash && \
pip3 install --no-cache-dir pyyaml Cython scons pycapnp pre-commit pylint parameterized coverage numpy
pip3 install --no-cache-dir pyyaml Cython scons pycapnp pre-commit ruff parameterized coverage numpy

WORKDIR /project/
RUN cd /tmp/ && \
Expand Down
6 changes: 6 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# https://beta.ruff.rs/docs/configuration/#using-pyprojecttoml
[tool.ruff]
select = ["E", "F", "W"]
ignore = ["W292", "E741"]
line-length = 160
target-version="py311"

0 comments on commit f92faca

Please sign in to comment.