tests(check): add support for '#aa:lint ignore' inline directive to disable linting.

This commit is contained in:
Alexandre Pujol 2025-07-21 22:22:13 +02:00 committed by Alex
parent f6914a8730
commit b2910ae593
2 changed files with 19 additions and 1 deletions

View file

@ -106,6 +106,9 @@ func Run(file *paths.Path, profile string) (string, error) {
opt := NewOption(file, match)
drtv, ok := Directives[opt.Name]
if !ok {
if opt.Name == "lint" {
continue
}
return "", fmt.Errorf("unknown directive '%s' in %s", opt.Name, opt.File)
}
profile, err = drtv.Apply(opt, profile)