Usage
The lint command is the default operation—you don’t need to specify a command name. Just run
vale followed by your input.Input Methods
Vale accepts three types of input, automatically detecting which method you’re using:Files and Directories
Provide one or more file or directory paths:String Arguments
If the argument doesn’t match an existing file or directory path, Vale treats it as literal text to lint:.txt file (or use --ext to specify a different format).
Standard Input
Pipe content to Vale via stdin:When using stdin, use the
--ext flag to specify the file format so Vale applies the correct syntax processing. Use --path to match configuration scope patterns.Output Formats
Control output format with the--output flag:
- CLI (default)
- JSON
- Line
- Custom template
Human-readable terminal output with color and formatting:
Common Options
Specify a custom configuration file path.By default, Vale searches for
.vale.ini in the current directory and parent directories.Set the minimum alert severity to display. Valid values: Only alerts at or above this level will be shown in output and affect the exit code.
suggestion, warning, error.Filter files using a glob pattern when linting directories.
Apply only rules matching the filter expression.
Disable syntax-aware processing and lint files line-by-line as plain text.This can be faster but loses context from markup structure.
Always exit with code 0, even when errors are found.Useful in CI when you want to see results but not fail the build.
Specify the file extension for stdin input.
Associate a file path with stdin for configuration matching.The path helps Vale determine which configuration scope to apply based on your
.vale.ini patterns.Examples
How Vale Processes Files
Configuration loading
Vale searches for
.vale.ini starting in the current directory and moving up the directory tree. It then loads styles and rules based on your configuration.File discovery
For directory inputs, Vale recursively finds files matching your format associations and glob patterns.
Syntax processing
Vale parses each file using a markup-aware processor based on the file extension (Markdown, AsciiDoc, HTML, etc.).
Scope matching
Vale applies rules to specific parts of the document based on scope configuration (e.g., only headings, or skip code blocks).
Exit Codes
| Code | Condition |
|---|---|
0 | No errors found, or --no-exit was used |
1 | One or more lint errors at or above minAlertLevel |
2 | Runtime error (invalid config, file not found, permission denied) |
Configuration Matching
Vale applies different configurations based on file paths using glob patterns in your.vale.ini:
.vale.ini
The
--path option lets you specify a virtual path for stdin input, allowing Vale to match the correct configuration section.Performance Tips
- Use
--globto limit which files are processed - Use
--filterto check only specific rules when debugging - Use
--ignore-syntaxfor faster processing of large plain text files - Configure
.vale.inito exclude directories withIgnorePaths
Related Commands
- ls-config - View your current configuration
- ls-metrics - Analyze file metrics
- sync - Install style packages