Skip to content

CLI Overview

The zzz CLI is the companion tool for the zzz web framework. It handles project scaffolding, code generation, database migrations, a development server with auto-reload, and utility commands for inspecting routes, running tests, and exporting OpenAPI specs.

The quickest way to install on macOS or Linux:

Terminal window
curl -fsSL https://zzz.seemsindie.com/install.sh | sh

To install a specific version:

Terminal window
ZZZ_VERSION=v0.1.0 curl -fsSL https://zzz.seemsindie.com/install.sh | sh
CommandAliasDescription
zzz new <name>Create a new zzz project with full directory structure
zzz serverzzz sStart a development server with auto-reload
zzz gen controller <Name>Generate a RESTful controller
zzz gen model <Name> [field:type ...]Generate a database model and migration
zzz gen channel <Name>Generate a WebSocket channel
zzz gen mailer <Name> [--template]Generate an email mailer module
zzz migrateRun pending database migrations
zzz migrate rollbackRoll back the last migration
zzz migrate statusShow current migration status
zzz routesList all application routes
zzz swaggerExport the OpenAPI specification as JSON
zzz testRun project tests via zig build test
zzz depsList workspace dependencies
zzz versionPrint the CLI version
Terminal window
zzz new blog
cd blog
zzz gen model Post title:string content:text published:boolean
zzz gen controller Posts
zzz gen channel Comments
zzz migrate
zzz server

After running these commands you will have a working project with a Post model, a RESTful Posts controller, a Comments WebSocket channel, and a development server listening on http://127.0.0.1:4000.

The zzz CLI and generated projects require:

  • Zig 0.16.0-dev.2535+b5bd49460 or later
  • zzz.zig framework (pulled in automatically via build.zig.zon)