Checking your code
dagger check
Runs all checks in your workspace in parallel. Exits non-zero if any check fails. Results are identical on your laptop, in CI, and in the cloud.
List checks
dagger check -l
Each row contains arguments for dagger check. Add dagger check before the row to run it. Rows group collection items by path. Use --all to list each key combination.
Filter checks
dagger check 'dag://eslint/*' # all checks from a module
dagger check dag://vitest/test # a single check
dagger check 'dag://*/lint' # pattern across modules
Use an absolute address to select a Git workspace from any directory:
dagger check github.com/dagger/dagger@main:golang
The dag:// prefix is optional for command arguments. One command can select one workspace. Relative addresses in the same command use that workspace.
Stop on first failure
By default every check runs so you see all failures at once. To cancel the rest as soon as one fails:
dagger check --failfast
Checks and generators
Each generator returns a Changeset. Its stale field is a Check that passes when the changeset is empty. For example, dag://assets/generate/stale checks dag://assets/generate.
Generated-file checks run by default, together with annotated check functions. Use --generated=false to skip generated-file checks:
dagger check --generated=false
The flag overrides the workspace's check-generated setting. Use --generated=true to include generated-file checks when that setting is false.
In CI
# GitHub Actions
- run: dagger check