cargo-rahti
Create and maintain Rahti projects.
cargo rahti new
Every flag adds a feature, and leaving it out is how you say no; an
interactive run asks about whatever was not named. A bare --db is SQLite.
A new project compiles and serves on the first cargo run. It carries:
- a working page with a server RPC, a root layout, and a stylesheet for the engine you chose (Tailwind or plain CSS);
- the PulsePoint browser runtime as a prebuilt asset — there is no JavaScript build step;
- a generated
.envwith a per-project session signing secret and cookie name, and a committed.env.examplecarrying a placeholder that release builds refuse to start on; - with
--db: SeaORM dependencies, a worked example entity and migration, and the process-wide connection insrc/db.rs; - with
--ws: thewsfeature on therahtidependency, which compiles#[socket]andrahti::ws; - its own documentation:
AGENTS.md— a project guide written for coding agents and the people beside them — and the framework's convention documents underdocs/conventions/.
cargo rahti upgrade
Every file the scaffold writes is recorded in rahti.config.json with its
hash at the moment of writing. upgrade compares: a file whose hash still
matches is the scaffold's and is brought up to date; one you edited is yours
and is left alone with a note; one you deleted stays deleted. Cargo.toml is
never regenerated from the template — your dependencies and a --local path
dependency are yours.
--db and --ws add a feature to a project that started without it, and
finish the job: the files are written, the choice is recorded, and the
manifest and .env are amended with the dependency, feature and connection
string the new files need. Additions only, and never twice — running it again
changes nothing.
License
Licensed under either of Apache License, Version 2.0 or MIT license at your option.