vx
A modern terminal-first CLI from Vandor Dev, built with Go, Cobra, and Bubble Tea.
vx is the local runtime CLI for vpkg packages and vxt templates.
The current public surface is project-local and preview-first. vx discovers packages from the nearest parent directory containing vpkg/, inspects packages and exports with vx view, and previews or applies template exports and direct .vxt files with vx gen.
Features
- Project-root discovery through the nearest parent containing
vpkg/ - Local package discovery from
vpkg/<namespace>/<package>/vpkg.yaml vx viewfor package, export, and direct.vxtinspectionvx genandvx generatefor preview-first template generation- TOML configuration with XDG-aware global and local lookup
- Config bootstrap and editor integration
- Shell completion for bash, zsh, fish, and PowerShell
- Documentation generation with
gomarkdoc, Astro Starlight, and Bun - Packaging and release scripts for GitHub Releases, Homebrew, and AUR
Requirements
- Go
- Just
- Bun
Quick Start
gh repo clone vandordev/vx
cd vx
just build
./bin/vxCommands
vx
vx view vandor/go-backend-core
vx view vandor/go-backend-core:default
vx view ./templates/usecase.vxt
vx gen vandor/go-backend-core --set name=create_booking
vx gen ./templates/usecase.vxt --set context=booking --apply
vx generate vandor/go-backend-core:default --set name=create_booking
vx config
vx config init
vx completion bashvx without arguments prints an overview of the local runtime commands and examples.
vx view is non-destructive:
- package targets show identity, version, kind, and declared exports
- export targets show metadata and, for
templateexports, required inputs from the.vxtcontract - direct
.vxttargets work when the file is inside the detected project root
vx gen is preview-first:
- only
templateexports and direct.vxtfiles are executable inv0.1 - output writes target the detected project root, not the current working directory
- files are written only with
--apply
Project Layout
vx expects a project-local vpkg/ tree such as:
my-project/
├── vpkg/
│ └── vandor/
│ └── go-backend-core/
│ ├── vpkg.yaml
│ └── templates/
│ └── usecase.vxt
└── templates/
└── standalone.vxtSupported target forms:
namespace/packagenamespace/package:export- unique shorthand package such as
go-backend-core - unique shorthand export such as
usecase - direct path such as
./templates/usecase.vxt
Configuration
Global configuration lives at $XDG_CONFIG_HOME/vx/config.toml, typically ~/.config/vx/config.toml.
Local overrides can also be stored in:
./.vx/config.tomlTo initialize a config file:
vx config init
vx config init --force
vx config init --editorTo open the resolved config file in your editor:
vx configSee example-config.toml for the available keys. Configuration does not control the root command behavior; runtime discovery comes from the local vpkg/ project layout.
Development
just build
just build-run
just watch
just dev-build
just test
just test-verbose
just cleanDocumentation
The docs site lives in docs/ and is built with Astro Starlight.
just docs-init
just docs-generate
just docs-dev
just docs-build
just docs-preview
just docs-cleanGenerated docs pull from:
- root markdown files such as
README.md,INSTALL.md,CONFIG.md, andCONTRIBUTING.md - command metadata in
cmd/vx - API docs generated from packages under
internal/
Release Tooling
This repository keeps the packaging and release flows in place:
just github-release <version>just init-homebrew-tapjust update-homebrew-formula <version>just init-aur-repojust update-aur-pkgbuild <version>just deploy-homebrew <version>just deploy-aur <version>
Repository Layout
.
├── cmd/vx
├── internal
├── docs
├── scripts
├── tests
└── justfilecmd/vxcontains the Cobra entrypoint and subcommands.internal/contains runtime services, config loading, package discovery, resolution, UI, adapters, and utilities.docs/contains the Starlight documentation site.scripts/contains release and packaging automation.
Installation
For macOS and Linux, install the latest release with:
curl -fsSL https://raw.githubusercontent.com/vandordev/vx/main/scripts/install.sh | shPin a release or change the install directory with:
VERSION=v0.1.0 curl -fsSL https://raw.githubusercontent.com/vandordev/vx/main/scripts/install.sh | sh
BIN_DIR=/usr/local/bin curl -fsSL https://raw.githubusercontent.com/vandordev/vx/main/scripts/install.sh | shFor Go users and Windows users, install the CLI from the executable package:
go install github.com/vandordev/vx/cmd/vx@latestThe repository root is a Go module, but the binary entrypoint lives in cmd/vx, so go install github.com/vandordev/vx@latest is not the correct install path.
See INSTALL.md for the full installation matrix and release distribution notes.
