Skip to main content

Gates

Gates are checks that run after a step completes. They can be deterministic (your project’s build tools) or non-deterministic (a workflow validator backed by an agent).

Declaring gates

Gates execute in order. All gates are evaluated even if one fails — the complete error context is available to the agent on retry. This lets the agent see all problems at once.

Built-in gates

Shell aliases

These resolve automatically based on your project type, or you can override them in gump.toml. Resolution cascade: heuristic (project markers) → gump.toml → inline bash: gate. compile and test are required — they fail if they can’t be resolved. lint and coverage are optional — skipped with a warning if the tool isn’t available.

Structural gates

Globs match on the basename, not the full path. "*_test.*" matches pkg/auth/middleware_test.go.

Custom gates

Runs any shell command. Exit 0 = pass, non-zero = fail. Stderr is captured as error context for retries.

Workflow validators

A workflow with type: validate (output = bool) can be used as a gate. This is how agent-backed reviews work in v0.0.4:
The validator workflow executes its own GET → RUN → GATE cycle. Its comments are accessible via {gate.review.comments} on retry. See Workflow Composition for details.

Combining gates

Gates are a list. Use as many as you need:

Overriding detection

If auto-detection picks the wrong commands, override in gump.toml:
Config overrides apply to all workflows in the project.