Skip to content

Add the hello example as the default starter - #222

Merged
vesperships merged 1 commit into
mainfrom
cursor/examples-hello-default-47cc
Sep 28, 2026
Merged

vesperships merged 1 commit into
mainfrom
cursor/examples-hello-default-47cc

Conversation

@KeKs0r

@KeKs0r KeKs0r commented Sep 28, 2026

Copy link
Copy Markdown
Member

What shipped

examples/hello is a two-table ClickHouse schema (users and events) with one generated migration and no dataset load. examples/manifest.json lists hello and sets it as the default. Getting Started, the with-an-example page, the agent instructions, and the root README point at hello. clickbench stays available as --example clickbench.

No product package source was edited. create-chkit reads default from examples/manifest.json and copies that file into the published package at build time (packages/create-chkit/scripts/copy-manifest.ts).

How to run

Scaffold, then claim a free ObsessionDB dev instance in the connect prompt (or set CLICKHOUSE_URL for local ClickHouse):

bun create chkit@latest my-chkit-app --example hello
cd my-chkit-app
bun run migrate
bunx chkit query "SELECT name FROM system.tables WHERE database = 'default' AND name IN ('users', 'events') ORDER BY name"

Or clone the folder:

cd examples/hello
bun install
bunx chkit obsessiondb signup
bunx chkit obsessiondb service claim
bun run migrate

Local ClickHouse instead of the claim:

export CLICKHOUSE_URL=http://localhost:8123
bun run migrate

ClickBench remains bun create chkit@latest my-app --example clickbench.

What I verified

  • bun install in a copy of examples/hello (and again inside the repo). Installed chkit, @chkit/core, and @chkit/plugin-obsessiondb at 0.1.2-beta.7. The example overrides resolved @orpc/client and @orpc/contract to 1.15.4.
  • chkit generate --name create_hello_schema wrote the migration and snapshot (2 definitions, 3 safe operations). A second generate reported an empty plan and did not add a migration. That no-op rewrites snapshot.json generatedAt; the committed snapshot is from the generation that wrote the SQL.
  • tsc --noEmit --strict on src/db/schema/hello.ts and clickhouse.config.ts passed. The example has no typecheck or generate script; those match examples/clickbench.
  • scripts/check-examples-manifest.ts passed (2 examples).
  • Loading packages/create-chkit/src/examples.ts from source returns default: "hello" and both example entries. packages/create-chkit unit tests passed (18).
  • apps/docs production build succeeded (48 raw markdown pages). The sitemap description for Start with an example is the new hello summary. Built HTML includes --example hello and --example clickbench.
  • bun verify was not run: doppler is not installed here, and there is no ClickHouse service.

Residual blockers

  • Nothing is listening on localhost:8123, and no CLICKHOUSE_* environment variables are set. bun run migrate was not applied.
  • The ObsessionDB claim needs a human email OTP (chkit obsessiondb signup, then chkit obsessiondb service claim). That was not run.

create-chkit default

The repository default is hello via examples/manifest.json. No packages/create-chkit source edit was required.

create-chkit default flip needs engineer packet only to republish create-chkit so the interactive prompt's bundled manifest includes hello and highlights it. Until that publish, bun create chkit@latest with no --example still prompts from the previously published manifest (default: clickbench, no hello entry). --example hello does not consult that list: it downloads github:obsessiondb/chkit/examples/hello#main and works once this merges. packages/create-chkit/README.md still documents only clickbench and was left unchanged.

No changeset. This diff is examples, docs, and a root README line. A create-chkit version bump belongs with that republish.

examples/hello is not a workspace package (unlike examples/clickbench), so the root lockfile is unchanged. bun install inside the folder installs it as its own project and writes a local bun.lock, which is not committed.

Open in Web Open in Cursor 

A two-table schema newcomers can migrate without the ClickBench load. The examples manifest default is hello; clickbench stays selectable.

Co-authored-by: Marc Höffl <marc.hoeffl@gmail.com>
@vesperships
vesperships marked this pull request as ready for review September 28, 2026 08:41
@vesperships
vesperships merged commit f9740a9 into main Sep 28, 2026
10 checks passed
@vesperships
vesperships deleted the cursor/examples-hello-default-47cc branch September 28, 2026 08:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants