Imported from GetRaider/idea-monorepo (
.cursor/skills/pre-pr-check/SKILL.md). Install upstream withnpx skills add GetRaider/idea-monorepo --skill pre-pr-check. Copyright stays with the author.
Pre-PR Check
Goal
Surface the same failures CI would catch before opening a PR.
Step 1 — Identify scope
From git diff main...HEAD --name-only (or git status), determine affected workspaces:
| Path prefix | Package |
|---|---|
apps/take-and-do/ |
take-and-do |
apps/devinity-api/ |
devinity-api |
apps/devinity-web/ |
devinity-web |
apps/personal-website/ |
personal-website |
packages/api/ |
@repo/api |
packages/ui/ |
@repo/ui |
packages/shared/ |
@repo/shared |
packages/eslint-config/ etc. |
config packages |
If root config changed (turbo.json, pnpm-workspace.yaml, commitlint.config.cjs), run full checks.
Step 2 — Run checks (from repo root)
Always (repo-wide)
pnpm codeCheck # tsc + lint via turbo
Per affected workspace
pnpm test --filter=<workspace>...
pnpm build --filter=<workspace>...
For devinity-web e2e (only if e2e-relevant changes):
pnpm test:e2e --filter=devinity-web
Full CI simulation (large changes)
pnpm codeCheck && pnpm test && pnpm build
Step 3 — Report
For each command, report:
- ✅ passed
- ❌ failed — paste relevant error lines and file paths
- ⏭️ skipped — with reason
Do not stop at first failure unless user asked — collect all failures.
Step 4 — Branch/commit hygiene (informational)
Remind if current branch or last commit may fail Husky:
- Branch:
<type>/<SCOPE>-<slug>, max 50 chars - Commit:
<type>(<SCOPE>): <subject>, max 70 chars, no body
See .cursor/rules/git-conventions.mdc.
take-and-do note
Staged lint runs via root .husky/pre-commit when apps/take-and-do/** is staged.
Constraints
- Run commands, don't just suggest them
- Use
--filterto avoid rebuilding unrelated apps when scope is narrow - Fix failures before recommending PR open