|
1 | 1 | # Agent instructions |
2 | 2 |
|
3 | | -## Data access |
| 3 | +GratiText helps people send thoughtful gratitude notes to loved ones on a |
| 4 | +regular schedule. |
4 | 5 |
|
5 | | -- Use typed SQL (generated `sql` helpers with `prisma.$queryRawTyped`). |
6 | | -- Do not use `prisma.$queryRaw` or `Prisma.sql`. |
7 | | -- Exception: Prisma typed SQL filenames must be valid JS identifiers (no |
8 | | - dashes), so the lower-kebab-case rule does not apply under `prisma/sql/`. |
| 6 | +## Essentials |
9 | 7 |
|
10 | | -## Full gate before push |
| 8 | +- Node version: `^24` |
| 9 | +- Build: `npm run build` (runs `build:icons`, then `react-router build`) |
| 10 | +- Typecheck: `npm run typecheck` (runs `react-router typegen`, then `tsc`) |
11 | 11 |
|
12 | | -You can push when you feel confident things are working, but immediately after |
13 | | -pushing, run the full gate to ensure everything is working (with the exception |
14 | | -of formatting, these can be run simultaneously with `npm run validate`). |
| 12 | +### Setup script |
15 | 13 |
|
16 | | -- Run formatting (`npm run format`). |
17 | | -- Run type checking (`npm run typecheck`). |
18 | | -- Run linting (`npm run lint -- --fix`). |
19 | | -- Run tests (`npm run test`, plus any relevant e2e suites). |
20 | | -- Only push after all checks pass. |
| 14 | +Run `npm run setup` to: |
21 | 15 |
|
22 | | -If anything changes as a result of running the full gate, commit and push that. |
23 | | -If you need to make changes to the codebase, do so in a separate commit and push |
24 | | -that as well. |
| 16 | +- Build the app |
| 17 | +- Ensure the Prisma DB is present |
| 18 | +- Generate the Prisma SQL |
| 19 | +- Migrate the DB |
| 20 | +- Seed the DB |
| 21 | +- Install the Playwright browsers |
| 22 | + |
| 23 | +## More instructions |
| 24 | + |
| 25 | +- [Data access rules](docs/agents/data-access.md) |
| 26 | +- [Git workflow rules](docs/agents/git-workflow.md) |
| 27 | +- [Routing](docs/agents/routing.md) |
| 28 | +- [Auth and session](docs/agents/auth-session.md) |
| 29 | +- [Environment and config](docs/agents/env-config.md) |
| 30 | +- [Testing](docs/agents/testing.md) |
| 31 | +- [Cron jobs and scheduling](docs/agents/cron-jobs.md) |
| 32 | +- [Caching and performance](docs/agents/caching-performance.md) |
| 33 | +- [UI and styling](docs/agents/ui-and-styling.md) |
| 34 | +- [Error handling](docs/agents/error-handling.md) |
| 35 | +- [Naming and structure](docs/agents/naming-and-structure.md) |
| 36 | +- [Scripts](docs/agents/scripts.md) |
| 37 | +- [Security](docs/agents/security.md) |
0 commit comments