mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-04-15 01:51:46 +04:00
Add types to manifests, make it and files optional
This commit is contained in:
parent
cebba0404d
commit
a4e9394cc7
3 changed files with 18 additions and 5 deletions
|
|
@ -27,7 +27,11 @@ MANIFEST_JSON_SCHEMA = {
|
|||
'minimum_pre_commit_version': {
|
||||
'type': 'string', 'default': '0.0.0',
|
||||
},
|
||||
'files': {'type': 'string'},
|
||||
'files': {
|
||||
'type': 'string',
|
||||
# empty regex to match all files
|
||||
'default': '',
|
||||
},
|
||||
'stages': {
|
||||
'type': 'array',
|
||||
'default': [],
|
||||
|
|
@ -35,19 +39,22 @@ MANIFEST_JSON_SCHEMA = {
|
|||
'type': 'string',
|
||||
},
|
||||
},
|
||||
'types': {
|
||||
'type': 'array',
|
||||
'items': {'type': 'string'},
|
||||
'default': ['file'],
|
||||
},
|
||||
'args': {
|
||||
'type': 'array',
|
||||
'default': [],
|
||||
'items': {
|
||||
'type': 'string',
|
||||
},
|
||||
'items': {'type': 'string'},
|
||||
},
|
||||
'additional_dependencies': {
|
||||
'type': 'array',
|
||||
'items': {'type': 'string'},
|
||||
},
|
||||
},
|
||||
'required': ['id', 'name', 'entry', 'language', 'files'],
|
||||
'required': ['id', 'name', 'entry', 'language'],
|
||||
},
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue