Configuration Files
Shadowtree config is TOML. By default, Shadowtree discovers the nearest
.shadowtree.toml by walking upward from the current directory.
Discovery stops at the outer Git repository boundary when the current directory
is inside a Git repository. Registered submodules continue into their
superprojects when they contain no nearer config. Independent nested repositories
and linked worktrees remain boundaries. An explicit --config PATH bypasses
discovery.
shadowtree --config ./ci.shadowtree.toml recipes
Minimal Config
[recipes.test]
help = "Run tests."
cmd = "go test ./..."
Run it with:
shadowtree test
Top-Level Fields
include = ["./common.shadowtree.toml"]
profile = "go"
shell = "sh"
shell_prelude = '''
shared_function() {
echo ok
}
'''
[env]
KEY = "value"
[vars]
NAME = "static value"
[var_commands]
DYNAMIC_NAME = "printf dynamic"
Field summary:
include: merge shared Shadowtree TOML files before the current config.profile: opt into built-in recipes forgoornode.shell: script shell for shell command strings; supported values areshandbash.shell_prelude: shell code prepended to every script command.env: environment values applied to recipe commands and top-levelvar_commands.vars: static placeholder values.var_commands: commands that compute placeholder values during recipe resolution.recipes: named workflow definitions.
Recipe Tables
Recipes live under [recipes.<name>]:
[recipes.build]
help = "Build the CLI."
cmd = 'go build -o "bin/{binary}" "{pkg}" {@}'
sync_out = ["bin/{binary}"]
[recipes.build.arguments.binary]
type = "string"
default = "shadowtree"
[recipes.build.arguments.pkg]
type = "string"
default = "./cmd/shadowtree"
values = "@go-main-packages"
Use Recipe Fields for recipe field details and Typed Arguments for argument definitions.