required-directive-name
Overview
This rule belongs to the yaml-syntax-validation ruleset and states that:
Directives are instructions to the YAML processor. They are identified by their name which is required and cannot be empty or null.
| Property | Value |
|---|---|
| Enabled | Yes |
| Maximum Severity | Blocking |
| Message | Directive name is missing. |
| Code | YAMLSYNTAX_V150 |
| Type | Validation |
| Rule System | Syntax |
| Broad Category | Directives |
| Tags | yaml data syntax preliminary checks validation yaml name directive |
Suggested Fixes
- % is used for declaring directives in YAML. If you don't intend to use any directives, remove the trailing %.
- Valid directives include %YAML, %TAG, etc.