fix: add classification for roles argument specs file (#235)

This commit is contained in:
Robert Kaussow 2021-10-10 22:14:01 +02:00 committed by GitHub
parent dde7eae3b8
commit b0271ef29b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 9 additions and 1 deletions

View File

@ -195,8 +195,10 @@ class Candidate(object):
return GroupVars(filename, settings, standards)
if "host_vars" in filename.split(os.sep):
return HostVars(filename, settings, standards)
if parentdir in ["meta"]:
if parentdir in ["meta"] and "main" in basename:
return Meta(filename, settings, standards)
if parentdir in ["meta"] and "argument_specs" in basename:
return ArgumentSpecs(filename, settings, standards)
if (
parentdir in ["library", "lookup_plugins", "callback_plugins", "filter_plugins"]
or filename.endswith(".py")
@ -312,6 +314,12 @@ class Meta(RoleFile):
pass
class ArgumentSpecs(RoleFile):
"""Object classified as Ansible roles argument specs file."""
pass
class Inventory(Unversioned):
"""Object classified as Ansible inventory file."""