CLI
AgileBuilder command-line tool
Overview
AgileBuilder CLI is a full-featured command-line tool supporting project generation, template management, local UI launch, MCP service management, and configuration.
Global Options
agilebuilder [command] [options]
Options:
-v, --version Show version number
-h, --help Show help information
--verbose Show detailed logs
--no-color Disable colored output
Common Commands
generate - Generate a Project
agilebuilder generate <template> <output> [options]
Arguments:
template Template name or path
output Output directory
Options:
-y, --yes Skip confirmation prompts
--no-hooks Skip hook execution
--var <key=value> Specify variable values
Examples:
agilebuilder generate react-starter my-app
agilebuilder generate react-starter my-app --var useTypeScript=true -y
template - Template Management
agilebuilder template <subcommand>
Subcommands:
list List all templates
add <url> Add a template from a Git URL
remove <name> Remove a template
create <path> Create a template from an existing project
info <name> View template details
sync Sync cloud templates
template add
agilebuilder template add <url> [options]
Options:
--name <name> Specify template name
--branch <branch> Specify Git branch
template create
agilebuilder template create <path> [options]
Options:
--name <name> Template name
--desc <description> Template description
ui - Launch Local UI
agilebuilder ui [options]
Options:
-p, --port <port> Specify port number (default: 3456)
--no-open Don't open browser automatically
mcp - MCP Service Management
agilebuilder mcp <subcommand>
Subcommands:
start Start MCP service
stop Stop MCP service
status Check service status
mcp start
agilebuilder mcp start [options]
Options:
-p, --port <port> Specify port number (default: 3457)
--daemon Run in background
config - Configuration Management
agilebuilder config <subcommand>
Subcommands:
list List all configuration
get <key> Get configuration value
set <key> <value> Set configuration value
reset Reset to default configuration
login/logout - Authentication
# Log in
agilebuilder login
agilebuilder login --email your@email.com
# Log out
agilebuilder logout
# Check login status
agilebuilder status
Environment Variables
| Variable | Description | Default |
|---|---|---|
AGILEBUILDER_HOME | Data directory | ~/.agilebuilder |
AGILEBUILDER_PORT | UI port | 3456 |
AGILEBUILDER_MCP_PORT | MCP port | 3457 |
Exit Codes
| Code | Description |
|---|---|
| 0 | Success |
| 1 | General error |
| 2 | Argument error |
| 3 | Template not found |
| 4 | Generation failed |
Configuration File
The CLI configuration file is located at ~/.agilebuilder/config.json:
{
"templateDir": "~/my-templates",
"defaultPackageManager": "pnpm",
"mcpPort": 3457,
"uiPort": 3456
}
Next Steps
- CLI Reference Manual - Complete CLI command reference
- MCP Service Configuration - Configure MCP service
- Quick Start (Local Edition) - Local edition quick start