Configuration
The YAML config schema — projects, repos, run, env management.
Banyan reads ~/.config/banyan/config.yaml (or $BANYAN_CONFIG if set). One file, all projects.
Minimal example
Full example
Repo fields
| Field | Description |
|---|---|
name | Repo identifier (used in tmux pane titles, branch names) |
path | Main checkout location. Stored as ~/... for portability. |
tech | Tech profile id picked at wizard time (node, spring-boot, android, django, custom). Drives the suggested defaults for run.command / port / portEnv. |
baseBranch | Default base for merge/rebase (else detected from origin/HEAD) |
mergeStrategy | squash / merge / rebase. Default: squash |
copyOnWorktree | Files to copy from main checkout → fresh worktree on bn wt. Relative paths only, no ... |
loadEnvFiles | .env-style files to parse and inject as env vars at run-time |
run.command | Shell command for bn start to spawn |
run.port | Canonical port. Banyan probes from port + 1 to allocate per feature. |
run.portEnv | Env var your framework reads (PORT, SERVER_PORT, …) |
run.setup | One-shot before each run (npm install, bundle install) |
run.stopCommand | Clean-shutdown command, run by bn stop / bn cleanup |
run.env | Extra env vars. Supports {{<repo>.port}} cross-repo templating |
run.composePorts | <env-var>: <service>:<containerPort> — inject host port of a compose service |
run.presets | Named alternative commands. Switch via activePreset |
type | git (default) or compose |
composeFile | For type: compose only — path to docker-compose.yml |
Top-level llm: block
Used by bn wt -p "<prompt>" to auto-name the branch from the prompt
via OpenRouter. Free models (e.g. x-ai/grok-4-fast:free) work fine.
The key can also come from the OPENROUTER_API_KEY env var, which
takes precedence over the config file. Skip the llm: block entirely
if you always pass an explicit feature name on bn wt.
Editing the config
Two ways:
- Edit
~/.config/banyan/config.yamldirectly. YAML, comments preserved across reloads. - Via the dashboard Config tab. Edits go through a comment-preserving writer. The Config tab also exposes the OpenRouter key (masked) and per-repo run command presets.
copyOnWorktree + loadEnvFiles
Most stacks depend on at least one gitignored file (.env, local.properties, application-local.yml). On bn wt, banyan copies declared files into the fresh worktree. On bn start, it parses .env-style files and prepends each KEY=value to the run command's env.
Banyan's dynamic values override file values:
loadEnvFilescontent (lowest)- allocated port + composePorts
- declared
run.env(highest)
So a .env.local shipping SERVER_PORT=8080 is overridden by banyan's allocated port for parallel features.