Paths and environment
The four state directories, their defaults, and the $BLINK_* variables.
blink writes per-project state (logs, build output) under a .blink/ directory and keeps user-scoped state under ~/.blink. The paths block relocates any of it, and a small set of $BLINK_* variables do the same from the environment for CI or containers.
Paths
The paths block declares the four directories blink reads and writes. Any field you leave empty is filled in this precedence order, the config file value first, then the matching $BLINK_* env override, then the derived default.
paths:
config_home: ~/.blink
control_dir: .blink
log_dir: .blink/logs
build_dir: .blink/build| Field | Default | Scope | Meaning |
|---|---|---|---|
config_home | $HOME/.blink | user | user-scoped state (auth, nag state, prefs). The only path nuke --global removes. |
control_dir | <dir_root>/.blink | project | per-project state root the other project paths derive from. |
log_dir | <control_dir>/logs | project | per-service .log files. |
build_dir | <control_dir>/build | project | compiled Go binaries. |
A relative override for control_dir, log_dir, or build_dir resolves against dir_root, while a relative config_home resolves against $HOME to match its user scope. An absolute value is used verbatim in every case.
Environment variables
blink reads a small set of $BLINK_* variables. BLINK_CONFIG is the env form of the -c flag, and the four path variables relocate where blink stores state. Every other setting is a flag only. The run, init, and nuke commands do not read a BLINK_* mirror of their flags.
| Variable | Flag | Command | Effect | Default |
|---|---|---|---|---|
BLINK_CONFIG | -c / --config | run, init, edit | explicit config path (skips walk-up), on init names the file to create | walk up from cwd (blink.yml on init) |
BLINK_CONFIG_HOME | (none) | paths | user-scoped state dir | $HOME/.blink |
BLINK_CONTROL_DIR | (none) | paths | per-project state root | <dir_root>/.blink |
BLINK_LOG_DIR | (none) | paths | per-service log dir | <control_dir>/logs |
BLINK_BUILD_DIR | (none) | paths | Go build output dir | <control_dir>/build |
Note
Because .env is auto-loaded before any override is read, any $BLINK_* variable can also be supplied through a top-level .env file. A value already exported in your shell still wins over the file.