AppView in a box as a Vite plugin thing
hatk.dev
1---
2title: CLI Overview
3description: All available Hatk CLI commands.
4---
5
6The `hatk` CLI manages your development workflow — generators, dev server, and builds. To create a new project, use `vp create github:hatk-dev/hatk-template-starter` (see [Quickstart](/getting-started/quickstart)).
7
8## Generators
9
10| Command | Description |
11| -------------------------------- | ----------------------------------- |
12| `hatk generate record <nsid>` | Generate a record lexicon |
13| `hatk generate query <nsid>` | Generate a query lexicon |
14| `hatk generate procedure <nsid>` | Generate a procedure lexicon |
15| `hatk generate feed <name>` | Generate a feed generator |
16| `hatk generate xrpc <nsid>` | Generate an XRPC handler |
17| `hatk generate label <name>` | Generate a label definition |
18| `hatk generate og <name>` | Generate an OpenGraph route |
19| `hatk generate types` | Regenerate TypeScript from lexicons |
20| `hatk destroy <type> <name>` | Remove a generated file |
21| `hatk resolve <nsid>` | Fetch a lexicon from the network |
22
23## Development
24
25| Command | Description |
26| ------------- | ----------------------------------------------- |
27| `hatk dev` | Start PDS, seed data, and run server with watch |
28| `hatk start` | Start the server (production mode) |
29| `hatk seed` | Run seed data against local PDS |
30| `hatk reset` | Wipe database and PDS |
31
32## Code Quality
33
34| Command | Description |
35| ------------- | ---------------------------------- |
36| `hatk test` | Run all tests |
37| `hatk check` | Type-check, lint, and format check |
38| `hatk format` | Auto-format code |
39
40## Build
41
42| Command | Description |
43| ------------ | --------------------------------- |
44| `hatk build` | Build the frontend for production |