Skip to content

Commit af3fcb6

Browse files
committed
Add black gh action and corresponding pre-commit.
1 parent 4bcfb16 commit af3fcb6

4 files changed

Lines changed: 187 additions & 4 deletions

File tree

.github/workflows/linters.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: Lint
2+
3+
on: [push, pull_request]
4+
5+
permissions:
6+
contents: read
7+
8+
jobs:
9+
lint:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v3
13+
- uses: psf/black@stable
14+
with:
15+
version: "~= 22.0"

.pre-commit-config.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
repos:
2+
- repo: https://github.com/psf/black
3+
rev: 22.10.0
4+
hooks:
5+
- id: black
6+
exclude: \.py-tpl$

poetry.lock

Lines changed: 163 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,12 @@ gql="2.0.0"
1515
multicaller=">=0.0.0a10"
1616
jstyleson="0.0.2"
1717
web3=">=5.19.0"
18-
black = "^22.12.0"
1918

2019
[tool.poetry.dev-dependencies]
20+
black = "^22.12.0"
2121
pytest="*"
22+
pre-commit = "^2.20.0"
2223

2324
[build-system]
2425
requires = ["poetry-core>=1.0.0"]
25-
build-backend = "poetry.core.masonry.api"
26+
build-backend = "poetry.core.masonry.api"

0 commit comments

Comments
 (0)