Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,3 @@
/packages/db/prisma/schema.prisma @aykhan019
/apps/api/src/modules/auth/ @aykhan019
/apps/api/src/modules/analytics/ @aykhan019
/HANDOFF.md @aykhan019
/CHECKLIST.md @aykhan019
6 changes: 2 additions & 4 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@

## Checklist

- [ ] Updated `CHECKLIST.md` (ticked completed items)
- [ ] Updated `HANDOFF.md` Section 2 if work is mid-flight
- [ ] Commits authored via `scripts/commit-as.sh`
- [ ] No external tool/model/product names in any artifact
- [ ] Tests added or updated where appropriate
- [ ] Docs or ADRs updated if behavior or architecture changed
- [ ] CI is green
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,7 @@ data/raw/

# Sentry source map uploads
.sentryclirc

# Course handout PDFs (not part of the project source)
/Guidelines-for-Group-Project (1).pdf
/Sample-Project-Report.pdf
268 changes: 0 additions & 268 deletions CHECKLIST.md

This file was deleted.

Empty file removed CLAUDE.md
Empty file.
40 changes: 3 additions & 37 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
# Contributing to Statify

This document is the operating manual for the four team members working on Statify.
This document is the operating manual for the team working on Statify.

## Read first

- `HANDOFF.md`, ground rules and current state.
- `CHECKLIST.md`, the master task list. Pick from here; do not invent tasks.
- `docs/adr/`, architectural decisions and rationale.
- `DESIGN.md`, the design system and token layer.

## Branching

Expand All @@ -17,23 +16,6 @@ This document is the operating manual for the four team members working on Stati

## Commits

All commits must be authored using `scripts/commit-as.sh`. Do not run `git commit` directly.

```bash
# Stage your changes first
git add <files>

# Then commit through the wrapper
scripts/commit-as.sh aykhan -m "feat(auth): add Argon2id password hashing"
scripts/commit-as.sh elshad -m "chore(ci): bump action versions"
scripts/commit-as.sh rahila -m "feat(web): add empty Track list page"
scripts/commit-as.sh eljan -m "feat(api): add /healthz endpoint"
```

The wrapper reads `scripts/.authors` and sets the commit author and committer environment variables for that single `git commit` call. It does not modify your global git config.

### Commit message format

Conventional Commits, enforced by commitlint in the `commit-msg` hook.

```
Expand All @@ -50,20 +32,13 @@ Scope examples: `auth`, `api`, `web`, `db`, `shared`, `ci`, `docs`.

Subject: imperative mood, lower case, no trailing period, under 72 chars.

### Forbidden

- No mention of external tools, models, or AI products in commit messages, code comments, PR bodies, or any artifact in this repository. (See `HANDOFF.md` Rule 1.)
- No `Co-Authored-By:` trailers.
- No raw `git commit`; use the wrapper.

## Pull Requests

- Open against `dev` for features and fixes.
- Use the PR template (`.github/pull_request_template.md`).
- Include a screenshot or short clip for any UI change.
- Note DB migrations explicitly: a PR that adds a Prisma migration must list it.
- CI must pass.
- Aykhan reviews and merges to `dev`. Merges to `main` are batched on release boundaries.
- CI must pass before merge.

## Code standards

Expand All @@ -86,12 +61,3 @@ Subject: imperative mood, lower case, no trailing period, under 72 chars.
- Never commit secrets. Use `.env.local` for personal overrides; it is gitignored.
- Validate every controller input through Zod.
- Use Prisma's parameterized queries. Raw queries use the `$queryRaw` tag, never `$queryRawUnsafe`.

## Updating the handoff

Before ending a working session:

1. Update `HANDOFF.md` Section 2 (Current State).
2. Tick completed items in `CHECKLIST.md`.
3. If anything was left mid-flight, write it under "Open threads" in `HANDOFF.md`.
4. Commit those updates.
218 changes: 0 additions & 218 deletions HANDOFF.md

This file was deleted.

56 changes: 0 additions & 56 deletions MERGE_PLAN.md

This file was deleted.

50 changes: 25 additions & 25 deletions docs/adr/0001-tech-stack-and-foundation.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,27 +11,27 @@ Four developers, zero budget, university project that also serves as a portfolio

## 2. Decision Summary

| Area | Decision | Free tier confirmed |
| ----------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------- |
| Backend | Node.js 22+ with TypeScript, NestJS 10 | Render free web service or Fly.io free allowance |
| ORM | Prisma 5 (Postgres provider) | OSS |
| Frontend | Next.js 15 (App Router), React 19, TypeScript | Vercel Hobby tier |
| Styling | Tailwind CSS 4, shadcn/ui, Radix primitives | OSS |
| Database | PostgreSQL 16 on Neon | 0.5 GB storage, 190 compute-hours/mo, branching |
| Auth | Email + password, Argon2id, JWT (access + refresh) in httpOnly cookies | Self-hosted |
| State (FE) | React Server Components first; TanStack Query for client; Zustand for ephemeral UI | OSS |
| Forms | React Hook Form, Zod | OSS |
| Validation | Zod schemas shared between FE and BE via `@statify/shared` | OSS |
| Email (future) | Resend free tier (100/day) | Yes |
| Monorepo | pnpm workspaces, single repo | Yes |
| Container (local) | Docker Compose for Postgres + adminer | Yes |
| CI/CD | GitHub Actions | Unlimited minutes on public repos |
| Hosting | Web on Vercel, API on Render free, DB on Neon | Yes; Render spins down after 15 min idle, warmed by cron-job.org |
| Error tracking | Sentry developer plan | 5k events/mo |
| Uptime | UptimeRobot | 50 monitors |
| Warm-up pings | cron-job.org | Unlimited 1-min jobs |
| Image/asset CDN | Use iTunes/Spotify image URLs directly | N/A |
| Audio | iTunes Search API `previewUrl` (30 s m4a) | Free, rate-limited |
| Area | Decision | Free tier confirmed |
| ----------------- | ------------------------------------------------------------------------------------------------ | ---------------------------------------------------------------- |
| Backend | Node.js 22+ with TypeScript, NestJS 10 | Render free web service or Fly.io free allowance |
| ORM | Prisma 5 (Postgres provider) | OSS |
| Frontend | Next.js 15 (App Router), React 19, TypeScript | Vercel Hobby tier |
| Styling | Tailwind CSS 4, shadcn/ui, Radix primitives | OSS |
| Database | PostgreSQL 16 on Neon | 0.5 GB storage, 190 compute-hours/mo, branching |
| Auth | Email + password, Argon2id, JWT (access + refresh) in httpOnly cookies | Self-hosted |
| State (FE) | React Server Components first; fetch-based API client for client calls; Zustand for ephemeral UI | OSS |
| Forms | React Hook Form, Zod | OSS |
| Validation | Zod schemas shared between FE and BE via `@statify/shared` | OSS |
| Email (future) | Resend free tier (100/day) | Yes |
| Monorepo | pnpm workspaces, single repo | Yes |
| Container (local) | Docker Compose for Postgres + adminer | Yes |
| CI/CD | GitHub Actions | Unlimited minutes on public repos |
| Hosting | Web on Vercel, API on Render free, DB on Neon | Yes; Render spins down after 15 min idle, warmed by cron-job.org |
| Error tracking | Sentry developer plan | 5k events/mo |
| Uptime | UptimeRobot | 50 monitors |
| Warm-up pings | cron-job.org | Unlimited 1-min jobs |
| Image/asset CDN | Use iTunes/Spotify image URLs directly | N/A |
| Audio | iTunes Search API `previewUrl` (30 s m4a) | Free, rate-limited |

## 3. Detailed Decisions

Expand All @@ -48,7 +48,7 @@ statify/
shared/ Zod schemas, DTO types, shared enums, error codes
db/ Prisma schema, migrations, seed scripts, MPD ingestion CLI
docs/ ADRs, ERD, API docs, onboarding, runbooks
scripts/ One-off shell scripts (commit attribution helper, etc.)
scripts/ One-off shell scripts (local setup, etc.)
.github/ Actions workflows, PR template, CODEOWNERS
report/ Academic submission artifacts
```
Expand Down Expand Up @@ -235,7 +235,7 @@ apps/web/src/

**State:**

- Server data: React Server Components for the initial render; TanStack Query for client-side mutations and revalidation. No Redux.
- Server data: React Server Components for the initial render; a thin fetch-based API client (`apps/web/src/lib/api-client.ts`) for client-side mutations and revalidation. No Redux.
- UI state (modals, sidebars, current playing track): Zustand. One store per concern.
- Form state: React Hook Form, validation via shared Zod schemas.

Expand Down Expand Up @@ -310,7 +310,7 @@ Branch model:
- Feature branches: `feat/<short-desc>`, `fix/<short-desc>`, `chore/<short-desc>`. Branched from `dev`.
- Hotfixes: branched from `main`, merged into `main` and back-merged to `dev`.

**Commit attribution:** every commit goes through `scripts/commit-as.sh <person-key>`. The wrapper sets `GIT_AUTHOR_*` and `GIT_COMMITTER_*` environment variables from `scripts/.authors` for that one commit. No global git config is modified. Aykhan reviews and merges PRs.
**Reviews:** changes land via pull request with CI green; a maintainer reviews and merges.

**PR template:** `.github/pull_request_template.md`, includes summary, screenshots (FE), DB migration noted, test plan, breaking changes.

Expand Down Expand Up @@ -376,7 +376,7 @@ Positive:
- Type safety from DB to UI; runtime validation matches compile-time types.
- Every architectural choice has a free-tier exit.
- The 12-table schema and 6 pre-planned advanced queries directly address the rubric.
- The `scripts/commit-as.sh` workflow keeps attribution clean.
- Conventional Commits keep history readable and enable changelog generation.

Negative:

Expand Down
2 changes: 1 addition & 1 deletion docs/adr/0002-design-system-and-token-layer.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ In Phase 6 (frontend redesign) the project commits to a visually energetic, mult
## 5. Migration

- `apps/web/src/app/globals.css` is rewritten in P6-M3 against the token surface summary in `DESIGN.md` §10. The existing 4-color + 5-radius + 2-font + 3-shadow set is replaced wholesale.
- New deps in `apps/web/package.json` (P6-M3): `lucide-react`, `tailwindcss-animate`, `@radix-ui/*` (set determined by which shadcn primitives the milestone needs), `next/font` is built in. Each addition gets a row in `HANDOFF.md` §3 Structural Changes Log.
- New deps in `apps/web/package.json` (P6-M3): `lucide-react`, `tailwindcss-animate`, `@radix-ui/*` (set determined by which shadcn primitives the milestone needs), `next/font` is built in. Each addition is recorded in the PR that introduces it.
- Existing components under `apps/web/src/components/{catalog,playlists,stats,player,admin,history,auth,ui}/` are destructively replaced milestone by milestone (P6-M5 through P6-M11). No backwards-compatibility shim.
- `packages/db/prisma/schema.prisma` gains `image_url String?` on `Artist`, `Album`, `Track` in P6-M4. Migration name: `entity_media`. Backfill script at `packages/db/src/scripts/backfill-media.ts` populates existing rows.
- `apps/web/next.config.js` `images.remotePatterns` allowlists `is*-ssl.mzstatic.com` (iTunes/Apple artwork hosts) in P6-M4. Recorded in the Structural Changes Log.
2 changes: 1 addition & 1 deletion docs/design/explorations.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,4 +127,4 @@ All three are energetic, multi-hue, color-confident. All three commit to real al
**Rationale (one line):** Section-as-color makes hue a structural element rather than decoration, which commits hardest to the multi-hue, color-confident posture, while leaving album art as the loudest variable visual element inside each section's room.
**Decided by:** Aykhan, 2026-05-24.

Recorded in HANDOFF.md Section 2. Next session opens P6-M2 (Author DESIGN.md from this direction).
Next milestone: author DESIGN.md from this direction.
Loading
Loading