github-action/prefer-file-extension
Enforce action file extension.
- 💼 This rule is enabled in the ✅
recommendedconfig.
📖 Rule Details
This rule reports when action file extension doesn't match.
yml
# yml.yml
name: Releasecorrect
yaml
# yaml.yaml
name: Releaseincorrect
🔧 Options
Default extension is set to yml.
ts
type AllowedExtension = 'yml' | 'yaml'
type JobIdCasingOptions = [
'error' | 'warn' | 'off' | 2 | 1 | 0,
(
| AllowedExtension
| {
extension?: AllowedExtension
/**
* @default true
*/
caseSensitive?: boolean
}
),
]"yml" (default)
Examples of correct code for this rule with default option:
yml
# yml.yml
name: Releasecorrect
Examples of incorrect code for this rule with default option:
yaml
# yaml.yaml
name: Releaseincorrect
"yaml"
Examples of correct code for this rule with "yaml" option:
yaml
# yaml.yaml
name: Releasecorrect
Examples of incorrect code for this rule with "yaml" option:
yml
# yml.yml
name: Releaseincorrect
🚀 Version
This rule was introduced in eslint-plugin-github-action v0.0.8