Skip to content

.vibe.toml

The .vibe.toml file contains shared configuration that is typically committed to git and shared with your team.

Copy individual files from the origin repository to the worktree:

[copy]
files = [".env", "config.json"]

The files array supports glob patterns for flexible file selection:

[copy]
files = [
"*.env", # All .env files in root
"**/*.json", # All JSON files recursively
"config/*.txt", # All .txt files in config/
".env.production" # Exact paths still work
]

Supported patterns:

PatternDescription
*Matches any characters except /
**Matches any characters including / (recursive)
?Matches any single character
[abc]Matches any character in brackets

Copy entire directories recursively:

[copy]
dirs = [
"node_modules", # Exact directory path
".cache", # Hidden directories
"packages/*" # Glob pattern for multiple directories
]

Control the number of parallel directory copy operations:

[copy]
concurrency = 8
  • Default: 4
  • Range: 1 to 32
  • Higher values may speed up copying on systems with fast storage (NVMe, SSDs)
  • Lower values reduce system resource usage

Environment variable override:

Terminal window
VIBE_COPY_CONCURRENCY=16 vibe start feat/my-feature

The environment variable takes precedence over the config file setting.

Copy Performance Optimization v0.4.0+

Section titled “Copy Performance Optimization ”

vibe automatically selects the best copy strategy based on your system:

StrategyWhen UsedPlatform
Clone (CoW)Directory copy on APFSmacOS
Clone (reflink)Directory copy on Btrfs/XFSLinux
rsyncDirectory copy when clone unavailablemacOS/Linux
StandardFile copy, or fallbackAll

How it works:

  • File copy: Always uses native copyFile() for best single-file performance
  • Directory copy: Automatically uses the fastest available method

Benefits:

  • Copy-on-Write is extremely fast as it only copies metadata, not actual data
  • No configuration needed - the best strategy is auto-detected
  • Automatic fallback ensures copying always works

See Hooks for details on configuring pre/post hooks.

Worktree Configuration v0.6.0+

Section titled “Worktree Configuration ”

Customize the worktree directory path using an external script.

Specify a script that outputs the worktree path:

[worktree]
path_script = "~/.config/vibe/worktree-path.sh"

The script receives these environment variables:

VariableDescriptionExample
VIBE_REPO_NAMERepository namemy-project
VIBE_BRANCH_NAMEBranch namefeat/new-feature
VIBE_SANITIZED_BRANCHSanitized branch name (/-)feat-new-feature
VIBE_REPO_ROOTRepository root path/path/to/repo

Example script:

~/.config/vibe/worktree-path.sh
#!/bin/bash
echo "${HOME}/worktrees/${VIBE_REPO_NAME}-${VIBE_SANITIZED_BRANCH}"
[copy]
files = [
".env",
".env.local",
"**/*.secret"
]
dirs = [
"node_modules",
".cache",
"vendor"
]
concurrency = 8
[hooks]
pre_start = ["echo 'Preparing worktree...'"]
post_start = [
"pnpm install",
"pnpm db:migrate",
"pnpm build"
]
pre_clean = ["git stash"]
post_clean = ["echo 'Cleanup complete'"]
[worktree]
path_script = "~/.config/vibe/worktree-path.sh"