Complete command reference for vx CLI. Use this skill when you need to look up specific command syntax, flags, or output formats. All commands support `--json` for structured output and `--format toon` for token-optimized output.
Install
npx skillscat add loonghao/vx/vx-commands Install via the SkillsCat registry.
SKILL.md
VX Command Reference
Structured Output Commands (AI-Optimized)
All commands support --json for structured output and --format toon for token-optimized output (saves 40-60% tokens).
Project Analysis
vx analyze --json # Analyze project structure
vx check --json # Verify tool constraints
vx ai context --json # Generate AI-friendly project contextOutput fields (analyze):
ecosystems[]- Detected ecosystems (nodejs, python, rust, go)dependencies[]- Project dependenciesscripts[]- Available scriptsrequired_tools[]- Tools needed
Output fields (check):
requirements[]- Tool requirement statusall_satisfied- Whether all constraints are metmissing_tools[]- Tools that need installation
Output fields (ai context):
project- Project info (name, languages, frameworks)tools[]- Installed tools with versionsscripts[]- Available scriptsconstraints[]- Tool constraints
Tool Management
vx list --json # List installed tools
vx versions node --json # List available versions
vx which node --json # Find tool location
vx search <query> --json # Search for toolsOutput fields (list):
runtimes[]- Available runtimestotal- Total countinstalled_count- Installed count
Output fields (versions):
versions[]- Available versions with metadatalatest- Latest versionlts- LTS version (if applicable)
Output fields (which):
path- Executable pathversion- Resolved versionsource- Source (vx, system, global_package)
Installation
vx install node@22 --json # Install tool
vx sync --json # Sync from vx.tomlOutput fields (install):
runtime- Tool nameversion- Installed versionpath- Installation pathduration_ms- Installation durationdependencies_installed[]- Dependencies also installed
Output fields (sync):
installed[]- Successfully installedskipped[]- Skipped (already installed)failed[]- Failed installationsduration_ms- Total duration
AI Integration
vx ai context # Generate AI-friendly context (Markdown)
vx ai context --json # JSON format
vx ai context --minimal # Minimal output
vx ai session init # Initialize session state
vx ai session status # Show session status
vx ai session cleanup # Clean up sessionEnvironment
vx env --json # Show environment variables
vx dev --export # Export shell environmentOutput Formats
JSON Format
vx list --json
# Output: {"runtimes": [...], "total": 50, "installed_count": 5}TOON Format (Token-Optimized)
vx list --format toon
# Output:
# runtimes[50]{name,installed,description}:
# node,true,Node.js runtime
# python,false,Python runtime
# ...TOON format is recommended for AI agents - it saves 40-60% tokens compared to JSON.
Environment Variable
export VX_OUTPUT=json # Default to JSON output
export VX_OUTPUT=toon # Default to TOON outputCommand Groups
Tool Execution
vx <tool> [args...] # Run any tool
vx npm install # Run npm
vx cargo build # Run cargoTool Management
vx install <tool>@<version> # Install tool
vx uninstall <tool> # Uninstall tool
vx list # List tools
vx versions <tool> # Show versions
vx which <tool> # Find tool path
vx switch <tool>@<version> # Switch versionProject Management
vx init # Initialize vx.toml
vx add <tool> # Add tool to project
vx remove <tool> # Remove tool from project
vx sync # Sync tools from vx.toml
vx lock # Generate vx.lock
vx check # Check constraintsScript Execution
vx run <script> # Run script from vx.toml
vx run --list # List available scriptsCache Management
vx cache dir # Show cache directory
vx cache clean # Clean cacheGlobal Flags
--json # JSON output
--format <text|json|toon> # Output format
--verbose # Verbose output
--debug # Debug output
--use-system-path # Use system PATH
--cache-mode <mode> # Cache mode (normal, refresh, offline, no-cache)Exit Codes
0- Success1- General error2- Tool not found3- Installation failed4- Version not found