Getting started

There are two ways in. They make the same site and differ in one thing: where duckdown's code lives. Your content (site/: pages, templates, static files) never depends on which you chose.

Install it

The default. duckdown is a dependency, and an upgrade is one command.

bunx github:blueshed/duckdown create my-site
cd my-site && bun run dev

create makes my-site/ on the newest release of duckdown: site/, .env, .gitignore, .railway/railway.ts and the authoring skill, with duckdown installed and pinned to that release, and the first commit made. A site that deploys by railway up rather than from GitHub adds --deploy up.

A folder you already have takes duckdown the same way by hand: bun add github:blueshed/duckdown#vX.Y.Z (a release: its tags on GitHub), then bunx duckdown init, then bun install. init never overwrites: anything already there is left alone, and it says what it skipped.

To upgrade later:

bunx duckdown upgrade

It exports the site before and after, and shows you what changed.

Create it

When you want to own the code.

bun create blueshed/duckdown my-site
cd my-site && bun run dev

bun create copies duckdown and sets the site up the same way, first commit included. The code is in ./server/ and the tests in ./tests/, at 100% coverage: yours to change, with the suite that guards them. There is no upgrade path, so fork duckdown on GitHub if you want to own the code and still take what comes upstream.

Editing

Open http://localhost:8080/edit and sign in with admin / admin. The editor has three columns:

The header holds the rest: Resources (pictures, stylesheets, templates, the site's icon, reports), Editors (who can sign in), Help, Translations and, when the site is published from there, Publish.

Publishing

DUCKDOWN_ORIGIN=https://example.com bun run export

That writes the whole site to dist/ as plain files, ready for any static host. bun run build is the same with --strict, which stops on a broken link rather than publishing it.