Skip to content

Commit 795fb66

Browse files
Add pre-commit linting to CI (#660)
* Run pre-commit in CI * Remove black and flake8 from scripts * Update to newer pre-commit revisions * Update Actions versions
1 parent d05ae25 commit 795fb66

File tree

3 files changed

+9
-4
lines changed

3 files changed

+9
-4
lines changed

.github/workflows/ci.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,3 +59,10 @@ jobs:
5959
run: |
6060
source ci/${{ matrix.jobqueue }}.sh
6161
jobqueue_after_script
62+
63+
lint:
64+
runs-on: ubuntu-latest
65+
steps:
66+
- uses: actions/checkout@v3
67+
- uses: actions/setup-python@v3
68+
- uses: pre-commit/[email protected]

.pre-commit-config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
repos:
22
- repo: https://github.com/psf/black
3-
rev: 24.2.0
3+
rev: 24.8.0
44
hooks:
55
- id: black
66
language_version: python3
77
- repo: https://github.com/pycqa/flake8
8-
rev: 7.0.0
8+
rev: 7.1.1
99
hooks:
1010
- id: flake8
1111
types: [file, python]

ci/none.sh

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@ function jobqueue_install {
1010
}
1111

1212
function jobqueue_script {
13-
flake8 -j auto dask_jobqueue
14-
black --exclude versioneer.py --check .
1513
pytest --verbose
1614
}
1715

0 commit comments

Comments
 (0)