Move source files to src/

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
agent
2026-03-24 09:26:46 -04:00
parent 634bf3353f
commit d2f2e32978
9 changed files with 10 additions and 9 deletions

View File

@@ -49,12 +49,12 @@ The scripts in this repo should collectively cover:
### Shared modules
- **`lib/auth.ts`** — exports the `Session` interface and `createSession()`, which launches headless Chromium, logs in, handles forced password changes, and returns `{ browser, page }`. Throws if login fails.
- **`lib/gitea.ts`** — All Gitea operations, each typed with explicit return interfaces. Functions take a `Session` plus operation-specific args, navigate to the relevant Gitea page, and return scraped data.
- **`src/lib/auth.ts`** — exports the `Session` interface and `createSession()`, which launches headless Chromium, logs in, handles forced password changes, and returns `{ browser, page }`. Throws if login fails.
- **`src/lib/gitea.ts`** — All Gitea operations, each typed with explicit return interfaces. Functions take a `Session` plus operation-specific args, navigate to the relevant Gitea page, and return scraped data.
Each tool call in `server.ts` creates a fresh session via `withSession<T>()` and closes the browser when done.
Each tool call in `src/server.ts` creates a fresh session via `withSession<T>()` and closes the browser when done.
### Standalone scripts
- **`login.ts`** — Standalone login smoke test.
- **`inspect.ts`** — Dumps form element metadata from the login page as JSON; useful for updating Playwright selectors when Gitea's HTML changes.
- **`src/login.ts`** — Standalone login smoke test.
- **`src/inspect.ts`** — Dumps form element metadata from the login page as JSON; useful for updating Playwright selectors when Gitea's HTML changes.