diff --git a/frontend/website/package.json b/frontend/website/package.json index e70648e..75587b0 100644 --- a/frontend/website/package.json +++ b/frontend/website/package.json @@ -10,10 +10,14 @@ "build-only": "vite build", "type-check": "vue-tsc --build", "test:e2e": "cypress run", - "lint": "run-s \"lint:*\"", + "lint": "run-s lint:oxlint lint:eslint", "lint:oxlint": "oxlint . --fix", "lint:eslint": "eslint . --fix --cache", - "format": "oxfmt src/" + "lint:check": "run-s lint:oxlint:check lint:eslint:check", + "lint:oxlint:check": "oxlint .", + "lint:eslint:check": "eslint . --cache", + "format": "oxfmt src/", + "format:check": "oxfmt --check src/" }, "dependencies": { "pinia": "^4.0.2", diff --git a/justfile b/justfile index 37b0450..ecd141f 100644 --- a/justfile +++ b/justfile @@ -3,5 +3,53 @@ set shell := ["bash", "-c"] default: @just --list +# Full completion gate. Start the worktree stack before running it because +# Cypress exercises the frontend and its backend wiring. +test-all: + @echo "==> frontend format + lint checks" + just frontend-format-check + just frontend-lint-check + @echo "==> frontend type check" + just frontend-type-check + @echo "==> backend static analysis" + just backend-types-check + @echo "==> frontend production build" + just frontend-build + @echo "==> backend tests" + just backend-test + @echo "==> frontend Cypress tests" + just frontend-cypress-run + +# Backend + +backend-test *args: + cd backend && php artisan test {{args}} + +backend-types-check: + cd backend && composer types:check + fresh: cd backend && php artisan migrate:fresh --seed + +# Frontend + +frontend-format: + cd frontend/website && npm run format + +frontend-format-check: + cd frontend/website && npm run format:check + +frontend-lint: + cd frontend/website && npm run lint + +frontend-lint-check: + cd frontend/website && npm run lint:check + +frontend-type-check: + cd frontend/website && npm run type-check + +frontend-build: + cd frontend/website && npm run build-only + +frontend-cypress-run: + cd frontend/website && npm run test:e2e