Skip to content

Commit 2296477

Browse files
committed
Fix pre-commit and blank line checks
1 parent 202135d commit 2296477

3 files changed

Lines changed: 7 additions & 6 deletions

File tree

.github/workflows/lint.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,5 @@ jobs:
4747
- name: Install dependencies
4848
run: just install
4949

50-
- name: Install pre-commit hooks
51-
run: pre-commit install --install-hooks
52-
5350
- name: Run lint and type checks
5451
run: just lint

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,9 +95,11 @@ The system is designed for graceful failure, not silent corruption. Unparseable
9595
```bash
9696
python3 -m venv .venv
9797
source .venv/bin/activate
98-
python3 -m pip install -r requirements.txt
98+
just install
9999
```
100100

101+
`just install` installs the backend and frontend dependencies and registers the repository's `pre-commit` hooks, so `git commit` runs the configured lint and test hooks locally.
102+
101103
1. Run `just dev` to start Django, Celery, Postgres, Redis, Qdrant, and Nginx. On the first run Docker builds the app image automatically. After that, `just dev` reuses the existing image so normal restarts are fast. If `.env` is missing, the `just` command copies `.env.example` automatically.
102104
2. Run `just build` after changing `requirements.txt` or `docker/web/Dockerfile`.
103105
3. For a fully fresh local stack after schema changes, run `just reset-volumes` before starting the containers again. This drops the Docker-backed Postgres, Redis, and Qdrant state so regenerated migrations apply cleanly.

justfile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,10 @@ frontend-install:
1212
install:
1313
just backend-install
1414
just frontend-install
15+
just install-hooks
16+
17+
install-hooks:
18+
if git rev-parse --git-dir >/dev/null 2>&1; then pre-commit install --install-hooks; fi
1519

1620
backend-dev:
1721
if [ ! -f .env ]; then cp .env.example .env; fi
@@ -47,8 +51,6 @@ backend-lint:
4751
djlint core/templates --check
4852
python3 -m mypy
4953
pre-commit run --all-files check-yaml
50-
pre-commit run --all-files end-of-file-fixer
51-
pre-commit run --all-files trailing-whitespace
5254
python3 manage.py check
5355

5456
frontend-lint:

0 commit comments

Comments
 (0)