You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
3
+
This file provides guidance to Claude Code (claude.ai/code) when working with
4
+
code in this repository.
4
5
5
6
## What is Starpod?
6
7
7
-
Starpod is an open-source Astro-based podcast website generator. It creates a full podcast site from an RSS feed and a `starpod.config.ts` configuration file. The reference deployment is [whiskey.fm](https://whiskey.fm) (Whiskey Web and Whatnot podcast).
8
+
Starpod is an open-source Astro-based podcast website generator. It creates a
9
+
full podcast site from an RSS feed and a `starpod.config.ts` configuration file.
10
+
The reference deployment is [whiskey.fm](https://whiskey.fm) (Whiskey Web and
11
+
Whatnot podcast).
8
12
9
13
## Commands
10
14
11
15
-**Dev server:**`pnpm dev` (runs on localhost:4321)
12
-
-**Build:**`pnpm build` (runs `astro check` then `astro build --remote`)
16
+
-**Build:**`pnpm build` (runs `astro check` then `astro build`)
13
17
-**Lint:**`pnpm lint` (ESLint with caching)
14
18
-**Lint fix:**`pnpm lint:fix`
15
19
-**All tests:**`pnpm test` (runs unit + e2e concurrently)
16
20
-**Unit tests only:**`pnpm test:unit` (Vitest)
17
21
-**Single unit test:**`pnpm exec vitest run tests/unit/Player.test.tsx`
18
22
-**E2E tests only:**`pnpm test:e2e` (Playwright, auto-starts dev server)
19
23
-**Seed remote DB:**`pnpm db:seed`
24
+
-**Push schema to DB:**`pnpm db:push`
25
+
-**Drizzle Studio:**`pnpm db:studio`
20
26
21
27
## Architecture
22
28
@@ -25,37 +31,60 @@ Starpod is an open-source Astro-based podcast website generator. It creates a fu
25
31
-**Astro 5** with static output, deployed to Vercel
26
32
-**Preact** for interactive components (player, search, contact form)
27
33
-**Tailwind CSS v4** via Vite plugin
28
-
-**Astro DB**(Turso/libSQL) for episode guests and sponsors
34
+
-**Drizzle ORM**with Turso/libSQL for episode guests and sponsors
29
35
-**Valibot** for config validation
30
36
31
37
### Key Configuration
32
38
33
-
-`starpod.config.ts` — podcast metadata (hosts, platforms, RSS feed URL, description). Uses `defineStarpodConfig()` from `src/utils/config.ts` for type safety and validation.
34
-
-`astro.config.mjs` — Astro config with Vercel adapter, Preact, sitemap, and DB integrations.
description). Uses `defineStarpodConfig()` from `src/utils/config.ts` for type
41
+
safety and validation.
42
+
-`astro.config.mjs` — Astro config with Vercel adapter, Preact, and sitemap
43
+
integrations.
44
+
-`drizzle.config.ts` — Drizzle Kit config for schema push, migrations, and
45
+
studio.
35
46
36
47
### Data Flow
37
48
38
-
Episodes are fetched from the RSS feed at build time via `src/lib/rss.ts`. Guest/sponsor data lives in `db/data/` as TypeScript files and is seeded to Turso via `db/seed.ts`. The DB schema is in `db/config.ts` with tables: Episode, Person, HostOrGuest, Sponsor, SponsorForEpisode.
49
+
Episodes are fetched from the RSS feed at build time via `src/lib/rss.ts`.
50
+
Guest/sponsor data lives in `db/data/` as TypeScript files and is seeded to
51
+
Turso via `db/seed.ts`. The DB schema is in `db/schema.ts` (Drizzle ORM) with
52
+
tables: Episode, Person, HostOrGuest, Sponsor, SponsorForEpisode. The DB
53
+
connection is configured in `db/index.ts`.
39
54
40
55
### Source Structure
41
56
42
-
-`src/pages/` — Astro pages and API routes. Dynamic episode pages use `[episode].astro`. LLM-friendly `.html.md.ts` endpoints generate markdown versions.
43
-
-`src/components/` — Mix of `.astro` (static) and `.tsx` (Preact interactive) components. The audio player (`src/components/player/`) and search dialog are Preact.
57
+
-`src/pages/` — Astro pages and API routes. Dynamic episode pages use
0 commit comments