Skip to content

Commit 01ba089

Browse files
committed
chore: add pre-commit ci
To avoid creating too much of a burder on newer/one-off developers, the pre-commit ci will run the checks, and where fixes can be done automatically, the GitHub Action will automatically create a new commit with the changes. Signed-off-by: JP-Ellis <josh@jpellis.me>
1 parent e75470d commit 01ba089

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed

.github/workflows/pre-commit.yml

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: pre-commit
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- master
7+
push:
8+
branches:
9+
- master
10+
11+
jobs:
12+
main:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v4
16+
17+
- name: Set up Python 3.x
18+
uses: actions/setup-python@v4
19+
with:
20+
python-version: 3.x
21+
22+
- name: Run pre-commit
23+
uses: pre-commit/action@v3.0.0
24+
25+
- name: Commit changes
26+
uses: pre-commit-ci/lite-action@v1.0.1
27+
if: always()

0 commit comments

Comments
 (0)