Skip to content

Commit 16fccb9

Browse files
committed
fix: env example in root, dot-env, turbo scripts
1 parent 115601c commit 16fccb9

File tree

13 files changed

+770
-4639
lines changed

13 files changed

+770
-4639
lines changed

.cursor/rules/01-MUST-DO.mdc

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
---
2+
description: Basic guidelines for the project so vibe coders don't fuck it up
3+
globs:
4+
alwaysApply: true
5+
---
6+
Always ensure type-safety, don't use type: any unless needed, when creating APIs, responses, or components, create proper interfaces and make them in the shared types folders where it fits best, not in the same file
7+
8+
When working on anything, try to split off components, utils, anything reusable to ensure better loading speed and less complexity
9+
10+
LESS COMPLEXITY IS BETTER, the fewer lines, the less complex logic the better
11+
12+
Naming convention is lower-case-like-this
13+
14+
Think about mobile responsiveness when doing any UI tasks or changes
15+
16+
NEVER add placeholders, mock data, or anything similar
17+
18+
Always use rounded, not rounded-xl or rounded-md, always rounded
19+
20+
ALWAYS use bun, never npm, never pnpm, just bun
21+
22+
Don't use lucide for icons, ONLY use phosphor icons, use width="duotone" for most, but for arrows use fill, for plus icons don't add width
23+
24+
Handle complex data transformations independently of React.
25+
Keep these modules decoupled from React for improved modularity and testability.
26+
View Components:
27+
28+
Decouple state management, data transformations, and API interactions from the React lifecycle.
29+
Simplify data flow to eliminate prop drilling and callback hell.
30+
Prioritize modularity and testability in all components.
31+
32+
Never throw errors in server actions, use try catch and return the error to the client
33+
34+
For all blogs and content pages, add TL;DRs near the title on the top for better conversion
35+
36+
ALWAYS use error boundaries properly
37+
38+
use console properly, like console.error, console.time, console.json, console.table, etc
39+
40+
Use Dayjs NEVER date-fns, and Tanstack query for hooks, NEVER SWR
41+
42+
Use ONLY Zod V4 from zod/v4 never zod 3 from zod
43+
44+
use Icon at the end of phosphor react icons, like CaretIcon not Caret
45+
46+
use json.stringify() when adding debugging
47+
48+
Almost NEVER use useEffect unless it's critical

.cursor/rules/ultracite.mdc

Lines changed: 333 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
---
2+
description: Use Bun instead of Node.js, npm, pnpm, or vite.
3+
globs: "*.ts, *.tsx, *.html, *.css, *.js, *.jsx, package.json"
4+
alwaysApply: false
5+
---
6+
7+
Default to using Bun instead of Node.js.
8+
9+
- Use `bun <file>` instead of `node <file>` or `ts-node <file>`
10+
- Use `bun test` instead of `jest` or `vitest`
11+
- Use `bun build <file.html|file.ts|file.css>` instead of `webpack` or `esbuild`
12+
- Use `bun install` instead of `npm install` or `yarn install` or `pnpm install`
13+
- Use `bun run <script>` instead of `npm run <script>` or `yarn run <script>` or `pnpm run <script>`
14+
- Bun automatically loads .env, so don't use dotenv.
15+
16+
## APIs
17+
18+
- `Bun.serve()` supports WebSockets, HTTPS, and routes. Don't use `express`.
19+
- `bun:sqlite` for SQLite. Don't use `better-sqlite3`.
20+
- `Bun.redis` for Redis. Don't use `ioredis`.
21+
- `Bun.sql` for Postgres. Don't use `pg` or `postgres.js`.
22+
- `WebSocket` is built-in. Don't use `ws`.
23+
- Prefer `Bun.file` over `node:fs`'s readFile/writeFile
24+
- Bun.$`ls` instead of execa.
25+
26+
Bun.serve({
27+
routes: {
28+
"/": index,
29+
"/api/users/:id": {
30+
GET: (req) => {
31+
return new Response(JSON.stringify({ id: req.params.id }));
32+
},
33+
},
34+
},
35+
// optional websocket support
36+
websocket: {
37+
open: (ws) => {
38+
ws.send("Hello, world!");
39+
},
40+
message: (ws, message) => {
41+
ws.send(message);
42+
},
43+
close: (ws) => {
44+
// handle close
45+
}
46+
},
47+
development: {
48+
hmr: true,
49+
console: true,
50+
}
51+
})
52+
```
53+
54+
For more information, read the Bun API docs in `node_modules/bun-types/docs/**.md`.

.env.example

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
CLICKHOUSE_URL="http://default:@localhost:8123/databuddy_analytics"
2+
DATABASE_URL="postgres://databuddy:databuddy_dev_password@localhost:5432/databuddy"
3+
REDIS_URL="redis://localhost:6379"
4+
5+
AI_API_KEY=""
6+
7+
BETTER_AUTH_URL="http://localhost:3000"
8+
BETTER_AUTH_SECRET="your_bcrypt_secret"
9+
10+
OPR_API_KEY=""
11+
12+
R2_ACCESS_KEY_ID=""
13+
R2_SECRET_ACCESS_KEY=""
14+
R2_BUCKET=""
15+
R2_ENDPOINT=""
16+
17+
AUTUMN_SECRET_KEY=""
18+
19+
NODE_ENV=development
20+
21+
LOGTAIL_SOURCE_TOKEN=""
22+
LOGTAIL_ENDPOINT=""
23+
24+
GITHUB_CLIENT_ID=""
25+
GITHUB_CLIENT_SECRET=""
26+
27+
GOOGLE_CLIENT_ID=""
28+
GOOGLE_CLIENT_SECRET=""
29+
30+
RESEND_API_KEY=""
31+
32+
NEXT_PUBLIC_API_URL="http://localhost:3001"

.gitignore

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,6 @@ node_modules
1212
.env.test.local
1313
.env.production.local
1414
.vscode
15-
# Rules
16-
Rules
1715

1816
# Testing
1917
coverage

0 commit comments

Comments
 (0)