Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions .github/workflows/run_precommit.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
---
name: pre-commit
name: prek

on:
pull_request:
push:
branches: [master]

jobs:
pre-commit:
prek:
runs-on: ubuntu-latest
steps:
- uses: actions/setup-python@v6
- uses: actions/checkout@v6
- uses: pre-commit/action@v3.0.1
- uses: j178/prek-action@v1
6 changes: 3 additions & 3 deletions .github/workflows/update_precommit_hooks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,10 @@ jobs:
with:
python-version: '3.12'
allow-prereleases: false
- name: Install pre-commit
run: pip install pre-commit
- name: Install prek
run: pip install prek
- name: Update pre-commit hooks
run: pre-commit autoupdate
run: prek auto-update
- name: Create Pull Request
uses: peter-evans/create-pull-request@v8
with:
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,4 +55,4 @@ cd neurodocker
python -m pip install --no-cache-dir --editable .[all]
```

Before committing changes, initialize `pre-commit` with `pre-commit install`. This will format code with each commit to keep the style consistent. _Neurodocker_ uses `ruff` for formatting.
Before committing changes, initialize `prek` with `prek install`, or `pre-commit` with `pre-commit install`. This will format code with each commit to keep the style consistent. _Neurodocker_ uses `ruff` for formatting.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ dev = [
"codecov",
"coverage[toml]",
"mypy",
"pre-commit",
"prek",
Comment thread
DimitriPapadopoulos marked this conversation as resolved.
"pytest >= 6.0",
"pytest-cov >= 2.0.0",
"pytest-reportlog >= 0.1.2",
Expand Down
Loading