CLI Reference
Complete reference for all Vandor CLI commands
Vandor CLI
The Vandor CLI is your primary tool for creating, managing, and extending Go backend projects. It is non-interactive by default -- you pass everything through flags and arguments. If you prefer guided prompts, add --interactive (or -it) to any command.
Command Structure
vandor [command] [subcommand] [args...] [flags]
Examples:
vandor new my-project --module github.com/myorg/my-project
vandor add domain order CreateOrder
vandor add usecase order CreateOrder
vandor vpkg add @official/http-humachi
vandor sync all
vandor dev:appCommand Tree
Here is the full command tree for Vandor v0.4:
vandor
|-- new <name> Create a new project
|-- add
| |-- context <name> Add a bounded context
| |-- domain <context> <name> Add a domain to a context
| |-- usecase <context> <name>Add a use case
| |-- service <context> <name>Add a domain service
| |-- valueobject <ctx> <name>Add a value object
|-- sync
| |-- context <name> Sync wiring for one context
| |-- core Sync aggregate wiring
| |-- all Sync everything
|-- vpkg
| |-- add <source> Install a package
| |-- remove <package> Remove a package
| |-- list List installed packages
| |-- search [query] Search the registry
| |-- info <package> Show package details
| |-- sync Re-apply all packages
| |-- exec <pkg> <action> Run a package action
| |-- exec-alias <alias> Run an aliased action
| |-- doctor Check project health
| |-- registry add|list|remove Manage registries
|-- run:app Start production app runner
|-- run:worker Start production worker runner
|-- dev:app Start dev app with hot reload
|-- dev:worker Start dev worker with hot reload
|-- tui Interactive terminal UI
|-- completion Generate shell completions
|-- theme Manage CLI themes
|-- upgrade Self-upgrade the CLI
|-- version Show version infoCommand Categories
Project Setup
Domain Layer
vandor add
Add contexts, domains, use cases, services, and value objects
vandor sync
Regenerate wiring code after adding or changing components
Runtime
Package Management
Interactive Tools
Utility Commands
vandor completion
Set up shell autocompletion for Bash, Zsh, Fish, and PowerShell
vandor theme
Manage CLI color themes
vandor upgrade
Upgrade the Vandor CLI to the latest version
vandor version
Show version and build information
Global Flags
These flags are available on every command:
--interactive, -it Enable interactive mode (prompts for missing values)
--no-input Disable all prompts; fail if required values are missing
--yes Automatically confirm all prompts
--output text|json Choose output format (default: text)
--help, -h Show help information
--version, -v Show version information
--config string Config file path (default: ./vandor-config.yaml)
--verbose Enable verbose output
--quiet Suppress output
--no-color Disable colored outputNon-interactive by default. Unlike earlier versions of Vandor, the CLI does not prompt you for anything unless you pass --interactive or -it. This makes it straightforward to use in scripts, CI pipelines, and automation workflows. When you do want guided prompts, just add -it and the CLI will walk you through the required inputs.
Configuration File
Vandor reads configuration from vandor-config.yaml in your project root:
project:
name: my-project
module: github.com/username/my-project
cli:
theme: mocha
interactive: false
vpkg:
registry: https://registry.vandor.dev
installed:
- @official/http-humachi
- @official/entgoExit Codes
0 Success
1 General error
2 Configuration error
3 Validation error
4 Generation error
5 Network errorEnvironment Variables
VANDOR_CONFIG # Path to config file
VANDOR_THEME # Override theme setting
VANDOR_REGISTRY # VPKG registry URL
VANDOR_NO_COLOR # Disable colors (set to any value)
VANDOR_VERBOSE # Enable verbose mode (set to any value)Quick Command Reference
| Command | Purpose | Example |
|---|---|---|
new | Create new project | vandor new my-api --module github.com/org/my-api |
add context | Add bounded context | vandor add context order |
add domain | Add domain | vandor add domain order Order |
add usecase | Add use case | vandor add usecase order CreateOrder |
add service | Add domain service | vandor add service order PriceCalculator |
add valueobject | Add value object | vandor add valueobject order Status --kind string --enum pending,completed |
sync all | Regenerate all wiring | vandor sync all |
sync context | Sync one context | vandor sync context order |
sync core | Sync aggregate wiring | vandor sync core |
vpkg add | Install package | vandor vpkg add @official/http-humachi |
vpkg list | List installed packages | vandor vpkg list |
run:app | Production app runner | vandor run:app |
dev:app | Dev app with hot reload | vandor dev:app |
tui | Interactive terminal UI | vandor tui |
theme set | Change theme | vandor theme set latte |
completion | Shell completion | vandor completion zsh |
upgrade | Update CLI | vandor upgrade |
Getting Help
For any command, use the --help flag:
vandor --help
vandor new --help
vandor add --help
vandor vpkg --help
vandor sync --helpNext Steps
- vandor new - Start by creating a project
- vandor add - Learn about adding domain components
- vandor vpkg - Explore package management
- vandor run / dev - Run your application