Skip to content

Commit 82e551d

Browse files
authored
Merge pull request #8 from adafruit/use_ruff
change to ruff
2 parents 748c847 + 3c37b62 commit 82e551d

9 files changed

+148
-463
lines changed

.gitattributes

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# SPDX-FileCopyrightText: 2024 Justin Myers for Adafruit Industries
2+
#
3+
# SPDX-License-Identifier: Unlicense
4+
5+
.py text eol=lf
6+
.rst text eol=lf
7+
.txt text eol=lf
8+
.yaml text eol=lf
9+
.toml text eol=lf
10+
.license text eol=lf
11+
.md text eol=lf

.pre-commit-config.yaml

Lines changed: 11 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,46 +1,21 @@
1-
# SPDX-FileCopyrightText: 2020 Diego Elio Pettenò
1+
# SPDX-FileCopyrightText: 2024 Justin Myers for Adafruit Industries
22
#
33
# SPDX-License-Identifier: Unlicense
44

5-
default_language_version:
6-
# force all unspecified python hooks to run python3.11
7-
python: python3.11
8-
95
repos:
10-
- repo: https://github.com/python/black
11-
rev: 23.3.0
12-
hooks:
13-
- id: black
14-
- repo: https://github.com/fsfe/reuse-tool
15-
rev: v1.1.2
16-
hooks:
17-
- id: reuse
186
- repo: https://github.com/pre-commit/pre-commit-hooks
19-
rev: v4.4.0
7+
rev: v4.5.0
208
hooks:
219
- id: check-yaml
2210
- id: end-of-file-fixer
2311
- id: trailing-whitespace
24-
- repo: https://github.com/pycqa/pylint
25-
rev: v2.17.4
12+
- repo: https://github.com/astral-sh/ruff-pre-commit
13+
rev: v0.3.4
14+
hooks:
15+
- id: ruff-format
16+
- id: ruff
17+
args: ["--fix"]
18+
- repo: https://github.com/fsfe/reuse-tool
19+
rev: v3.0.1
2620
hooks:
27-
- id: pylint
28-
name: pylint (library code)
29-
types: [python]
30-
args:
31-
- --disable=consider-using-f-string
32-
exclude: "^(docs/|examples/|tests/|setup.py$)"
33-
- id: pylint
34-
name: pylint (example code)
35-
description: Run pylint rules on "examples/*.py" files
36-
types: [python]
37-
files: "^examples/"
38-
args:
39-
- --disable=missing-docstring,invalid-name,consider-using-f-string,duplicate-code
40-
- id: pylint
41-
name: pylint (test code)
42-
description: Run pylint rules on "tests/*.py" files
43-
types: [python]
44-
files: "^tests/"
45-
args:
46-
- --disable=missing-docstring,consider-using-f-string,duplicate-code
21+
- id: reuse

0 commit comments

Comments
 (0)