Environment Variables
User-facing env vars consumed by the latdx CLI and core engine. CI/release-only vars live in docs/internal/environment-variables.md.
Precedence: CLI flag > env var > config file (latdx.config.json) > built-in default.
For steady-state configuration (batch mode, turbo workers, HTTP port, license key, default test mode, coverage), use latdx config set instead of env vars. Env vars below are reserved for ephemeral overrides and debug escape hatches.
Logging & Output
| Variable | Default | Values | Purpose |
|---|---|---|---|
LATDX_LOG_LEVEL | warn | error, warn, warning, info, debug, trace, off, silent | CLI log verbosity. Overridden by -q / -v. (warning aliases warn; silent aliases off.) |
LATDX_LOG_FORMAT | text | text, json | Output format. Overridden by --json. |
NO_COLOR | unset | any non-empty | Disable ANSI color (per no-color.org ). Also honored via --no-color. |
CI | unset | any non-empty | Disable spinners and live renderer; force plain output. |
LATDX_DEBUG | unset | true / 1, namespace patterns | Enable namespaced trace channels (stderr). See LATDX_DEBUG namespace patterns in cli-reference.md. |
Salesforce Integration
| Variable | Default | Values | Purpose |
|---|---|---|---|
LATDX_SF_INSTALL_METHOD | MANAGED_PKG | SOURCE, MANAGED_PKG | How latdx-sf installs into the org. SOURCE for dev; MANAGED_PKG for prod. Legacy alias SF_PACKAGE_INSTALL_METHOD is honored with a deprecation warning. |
LATDX_SF_SOURCE_PATH | auto-discovered | absolute path | Override path to the latdx-sf/src/main directory. Highest-priority resolution. |
LATDX_SF_PACKAGE_ID | baked-in 04t... | 04t... ID | Managed package version ID. Env var beats the compile-time define in release binaries. |
LATDX_SF_PACKAGE_VERSION | baked-in | semver string | Minimum managed-package version expected in the org. |
LATDX_SKIP_TEST_RUNNER_ACCESS | unset | 1, true | Skip auto-deploy/assign of the latdx_TestRunnerAccess permset. |
Diagnostics
| Variable | Default | Values | Purpose |
|---|---|---|---|
LATDX_KEEP_TEMP_FILES | unset | true | Keep temp working directories on disk after a run. Useful for support tickets. |
LATDX_KEEP_SF_LOGS | unset | true | Skip deletion of Apex debug logs after a run. |
Interactive Behavior
| Variable | Default | Values | Purpose |
|---|---|---|---|
LATDX_AUTO_CONFIRM | unset | true | Auto-confirm interactive prompts. Useful for non-interactive shells where CI=true is not set. |
Internal (set automatically; do not configure manually)
| Variable | Set by | Purpose |
|---|---|---|
LATDX_DAEMON | DaemonSpawner | Signals the child process is running in daemon mode. |
LATDX_DAEMON_LOG | DaemonSpawner | Daemon log file path. |
LATDX_DAEMON_IPC_ENDPOINT | CLI / DaemonSpawner | IPC socket / named-pipe path used by the daemon. |
LATDX_WORKSPACE_ID | DaemonSpawner | Workspace identity passed to daemon child. |
LATDX_WORKSPACE_ROOT | DaemonSpawner | Worktree root passed to daemon child. |
SFDX_DISABLE_LOG_FILE, SF_DISABLE_LOG_FILE | CLI entrypoint | Disable SFDX file logging in Bun-compiled binaries. |
Removed / Deprecated
| Variable | Replacement |
|---|---|
LATDX_COVERAGE_ENABLED | latdx config set execution.enableCoverageAndDecoration <value> |
LATDX_BATCH_MODE | latdx config set execution.batchMode <eco|turbo> |
LATDX_TURBO_WORKERS | latdx config set execution.turboModeWorkers <n> |
LATDX_TEST_MODE | latdx config set execution.defaultTestMode <dbsim|full> |
LATDX_HTTP_ENABLED | latdx config set httpServer.enabled <bool> |
LATDX_HTTP_PORT | latdx config set httpServer.port <n> |
LATDX_LICENSE_KEY | latdx config set licenseKey <key> |
SF_PACKAGE_INSTALL_METHOD | LATDX_SF_INSTALL_METHOD (legacy alias still works with deprecation warning) |