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
4 changes: 2 additions & 2 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Dev container for T3 Code. Mirrors CI (ubuntu-24.04, Node 24, Rust stable)
// Dev container for T3 Code. Mirrors CI (ubuntu-24.04, Node 26, Rust stable)
// and the canonical setup in docs/operations/development.md: global `vp`, `vp i`.
// Contributor doc: docs/internals/devcontainer.md
{
Expand All @@ -8,7 +8,7 @@
// nodeGypDependencies (default true) brings python3/make/g++, which Linux
// needs for node-pty's node-gyp fallback (its prebuilds are mac/win only).
"ghcr.io/devcontainers/features/node:2": {
"version": "24"
"version": "26"
},
// native/resource-monitor (edition 2024, needs stable >= 1.85). The server
// degrades gracefully without the binary, but CI checks cargo fmt + test.
Expand Down
1 change: 1 addition & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ For authorized mobile verification, a missing or outdated native client is a bui
## Pull requests

- Never make a PR unless the developer explicitly asks you to do so.
- If `origin` is git.cafe, follow [GitCafe mirror](docs/operations/development.md#gitcafe-mirror-optional): use `cafe` for existing PRs, issues, comments and labels, but push and open PRs on GitHub, where CI runs.
- Conventional commit titles, plain language: `fix(web): new threads no longer spike CPU`.
- Body: the problem in a sentence or two, then how you fixed it. End with the model and harness that did the work.
- UI changes need before/after images. Motion or timing needs a short video.
Expand Down
2 changes: 1 addition & 1 deletion docs/internals/devcontainer.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

> For maintainers. Using T3 Code? See [docs/user](../user/).

`.devcontainer/` gives you a ready-to-code Linux environment matching CI: Ubuntu 24.04, Node 24, pnpm, Rust stable, the global `vp` CLI, and the GitHub CLI. Open the repo in VS Code and "Reopen in Container", or create a GitHub Codespace. Dependency install (`vp i`), the Electron exec-bit repair, and the Vite dep-cache warmup all run automatically before you attach.
`.devcontainer/` gives you a ready-to-code Linux environment matching CI: Ubuntu 24.04, Node 26, pnpm, Rust stable, the global `vp` CLI, and the GitHub CLI. Open the repo in VS Code and "Reopen in Container", or create a GitHub Codespace. Dependency install (`vp i`), the Electron exec-bit repair, and the Vite dep-cache warmup all run automatically before you attach.

## What works in the container

Expand Down
2 changes: 1 addition & 1 deletion docs/operations/background-verification.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Live background-work verification

Run from the repository root with Node 24 and installed dependencies. This uses
Run from the repository root with installed dependencies (`vp` provides the pinned Node). This uses
real provider CLI credentials and consumes model usage:

```sh
Expand Down
50 changes: 46 additions & 4 deletions docs/operations/development.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

## First checkout

Install `vp` using the [root README](../../README.md#install-vp). The checkout requires Node 24;
Bun is optional. From the repository root:
Install `vp` using the [root README](../../README.md#install-vp). It provides the Node version
pinned in `package.json` (Node 26), so no separate Node install is needed. From the repository root:

```sh
vp i
Expand All @@ -15,6 +15,47 @@ a new browser.

Prefer a container? See [Dev container](../internals/devcontainer.md) for VS Code and Codespaces setup.

## GitCafe mirror (optional)

GitHub is the source of truth. [git.cafe/pingdotgg/t3code](https://git.cafe/pingdotgg/t3code) is a
two-way synced mirror with much higher API rate limits, which helps when many agents read PRs and
issues at once. You never need it to contribute.

Comments, reviews, labels, and issue edits made on GitCafe sync back to GitHub. The exception is
code: push branches and open PRs on GitHub, where CI runs. GitCafe mirrors a new PR within about a
minute, and from then on you can work with it through either forge.

```sh
git remote set-url origin https://git.cafe/pingdotgg/t3code.git
git remote add github https://github.com/pingdotgg/t3code.git
# The GitHub remote you push to: `github`, or your fork's remote.
git config remote.pushDefault github
Comment thread
juliusmarminge marked this conversation as resolved.
Resolved
gh repo set-default pingdotgg/t3code
bun install -g @gitcafe/cli # `cafe` needs Bun 1.2 or newer
cafe auth login && cafe auth http setup
cafe skills install --global # optional: cafe-* skills for coding agents
```

With `origin` on git.cafe:

- Use `cafe` for existing PRs, issues, comments, reviews, and labels, both reading and writing. Check status
comes from `cafe pr status <n> --json`.
- Create PRs on GitHub: `git push` (to the `pushDefault` remote), then `gh pr create` or `gh stack`.
A PR opened with `cafe pr create` or `cafe stack submit` can get a different number on each forge,
a sync marker appended to its body, and rewritten references, and it cannot come from a fork.
- Write or edit text with closing keywords using `gh`. Any text GitCafe writes to GitHub has its
`#<n>` references turned into GitCafe links, so a `Fixes #<n>` edited through `cafe` silently stops
closing the issue.
- Merge with `gh pr merge <branch> --match-head-commit <sha>`. `cafe pr merge` only pins the head
GitCafe last saw, not the commit you reviewed.
- Use `gh` where the mirror falls short: CI logs and reruns, a fork PR's head repository, and
anything `cafe` returns empty or 403/404 for.
- PR and issue numbers can differ between the forges. Name PRs by branch
(`cafe pr list --head <branch>`, `gh pr view <branch>`), and write `Fixes #<GitHub number>`.
- `cafe` flags differ from `gh`: `--repo` not `-R`, `cafe issue comments <n>` not `--comments`,
`cafe pr status` not `pr checks`. This repository's CI is GitHub Actions on GitHub, so `cafe ci`
has no runs for it; read logs with `gh run view`. `cafe api` paths omit `/api` (`cafe api /repos/...`).

## Choosing a dev process

Use `vp run dev` for server and web, or `vp run dev:desktop` for the Electron client.
Expand All @@ -27,7 +68,9 @@ Add `--browser` to open a browser automatically.
### State and ports

Linked worktrees default to their own `.t3/userdata`, even when `T3CODE_HOME` is set.
The main checkout defaults to `~/.t3/dev/userdata`. An explicit `--home-dir` wins in both cases.
The main checkout defaults to `~/.t3/dev`. An explicit `--home-dir` wins in both cases.
The first start in a worktree seeds its empty database from a read-only copy of
`~/.t3/userdata`; `--no-seed` or `T3CODE_DEV_SEED=0` skips that.
Never run a development server against the live `~/.t3/userdata`.
See [test data](../../AGENTS.md#test-data) for copying a consistent database snapshot.

Expand Down Expand Up @@ -132,7 +175,6 @@ and runs in headless Chromium with the React Compiler on, like the app. There is
TypeScript workspaces typecheck with `tsc`. The `typescript` catalog entry is
`@tsc-rs/typescript`, the tsc-rs drop-in, with Effect diagnostics, quick fixes, and
refactors built in. VS Code uses it through `js/ts.tsdk.path` in `.vscode/settings.json`.
Marketing keeps `astro check` for Astro files.

Use `vp run lint:mobile` for native mobile changes. CI owns the full suite; see
[ci.yml](../../.github/workflows/ci.yml) for its current jobs.
Expand Down
2 changes: 1 addition & 1 deletion docs/user/install.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ Node.js for `npx`).
### Intel Macs

There is no `t3` executable for Intel Macs (the desktop app is available). To
run a server there, build it from source with Node.js 24 and `vp`
run a server there, build it from source with `vp`, which provides the Node version it needs
([Install vp](https://github.com/pingdotgg/t3code#install-vp)):

```bash
Expand Down
Loading