diff --git a/cptr/frontend/package.json b/cptr/frontend/package.json index 95a4012..13dedd2 100644 --- a/cptr/frontend/package.json +++ b/cptr/frontend/package.json @@ -8,8 +8,10 @@ "build": "vite build", "preview": "vite preview", "prepare": "svelte-kit sync || echo ''", - "format": "prettier --write .", - "format:check": "prettier --check .", + "format": "npm run format:frontend && cd ../.. && uv run ruff format cptr", + "format:check": "npm run format:check:frontend && cd ../.. && uv run ruff format --check cptr", + "format:frontend": "prettier --write .", + "format:check:frontend": "prettier --check .", "check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json", "check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch" }, diff --git a/package.json b/package.json new file mode 100644 index 0000000..b62289a --- /dev/null +++ b/package.json @@ -0,0 +1,11 @@ +{ + "private": true, + "scripts": { + "format": "npm run format:frontend && npm run format:backend", + "format:check": "npm run format:check:frontend && npm run format:check:backend", + "format:frontend": "npm --prefix cptr/frontend run format:frontend", + "format:check:frontend": "npm --prefix cptr/frontend run format:check:frontend", + "format:backend": "uv run ruff format cptr", + "format:check:backend": "uv run ruff format --check cptr" + } +}