Configuration

Gooze reads config from a file named gooze.yaml. This helps you keep the same settings in your repo and in CI.

Create a starter config

This command creates a starter gooze.yaml in the current directory.

gooze init

How config is loaded

  • File name: gooze.yaml
  • Location: the directory you run Gooze from
  • Environment variables: prefix GOOZE_(use _ instead of - and .)

Example: the flag --no-cache can be set via GOOZE_NO_CACHE=true.

Environment variables

Gooze can read settings from environment variables. The names are derived from config keys by prefixing GOOZE_, uppercasing, and replacing . and - with _.

Typical precedence is: CLI flags -> env vars -> config file -> defaults. For logging, --verbose and --log-output override env/config.

Env varWhat it controls
GOOZE_OUTPUTReports output directory
GOOZE_NO_CACHEDisable incremental cache when true
GOOZE_PATHS_EXCLUDEExclude patterns (comma-separated)
GOOZE_RUN_PARALLELWorker count for run
GOOZE_RUN_MUTATION_TIMEOUTPer-mutation timeout (seconds)
GOOZE_LOG_FILENAMELog file path
GOOZE_LOG_VERBOSEForce verbose logging when true
GOOZE_LOG_LEVELLog level (for example: debug, info, warn, error)
# Example: set output + disable cache for one run
export GOOZE_OUTPUT=.gooze-reports
export GOOZE_NO_CACHE=true

gooze run ./...
# Example: exclude vendor and mock files
export GOOZE_PATHS_EXCLUDE='^vendor/,^mock_'

gooze run ./...

A common config example

This example does: (1) sets output dir, (2) excludes vendor/examples, (3) sets parallel workers, (4) enables verbose logs.

# gooze.yaml
output: .gooze-reports
no-cache: false

run:
  parallel: 1
  # Some versions support a timeout flag/config.
  # Check: gooze run --help
  mutation_timeout: 120

paths:
  exclude:
    - '^vendor/'
    - '^examples/'

logging:
  verbose: false
  output: .gooze.log

CLI flags vs config

In most tools, CLI flags override config. If you see surprising behavior, print help and compare:

gooze --help
gooze run --help