ty/docs/reference/exit-codes.md
Micha Reiser 72ed4e7ec7
Some checks failed
CI / python package (push) Has been cancelled
CI / pre-commit (push) Has been cancelled
CI / Check generated files unedited (push) Has been cancelled
CI / mkdocs (push) Has been cancelled
Add IO errors to exit code documentation (#1589)
2025-11-19 10:03:14 +01:00

16 lines
770 B
Markdown

# Exit codes
The ty command line interface uses the following exit codes:
| Exit code | Description |
| :-------- | :------------------------------------------------------- |
| `0` | no violations with severity `error` or higher were found |
| `1` | violations with severity `error` or higher were found |
| `2` | invalid CLI options, invalid configuration, or IO errors |
| `101` | internal error |
ty supports two command line arguments that change how exit codes work:
- `--exit-zero`: ty will exit with `0` even if violations were found.
- `--error-on-warning`: ty will exit with `1` if it finds any violations with severity `warning` or
higher.