Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update JSON schema for modules meta.yml #5837

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
119 changes: 55 additions & 64 deletions modules/meta-schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,76 +38,14 @@
"type": "array",
"description": "Input channels for the module",
"items": {
"type": "object",
"patternProperties": {
".*": {
"type": "object",
"properties": {
"type": {
"type": "string",
"description": "Type of the input channel",
"enum": ["map", "file", "directory", "string", "integer", "float", "boolean", "list"]
},
"description": {
"type": "string",
"description": "Description of the input channel"
},
"pattern": {
"type": "string",
"description": "Pattern of the input channel, given in Java glob syntax"
},
"default": {
"type": ["string", "number", "boolean", "array", "object"],
"description": "Default value for the input channel"
},
"enum": {
"type": "array",
"description": "List of allowed values for the input channel",
"items": {
"type": ["string", "number", "boolean", "array", "object"]
},
"uniqueItems": true
}
},
"required": ["type", "description"]
}
}
"type": "array", "items": { "$ref": "#/definitions/elementProperties" }
}
},
"output": {
"type": "array",
"description": "Output channels for the module",
"items": {
"type": "object",
"patternProperties": {
".*": {
"type": "object",
"properties": {
"type": {
"type": "string",
"description": "Type of the output channel",
"enum": ["map", "file", "directory", "string", "integer", "float", "boolean", "list"]
},
"description": {
"type": "string",
"description": "Description of the output channel"
},
"pattern": {
"type": "string",
"description": "Pattern of the input channel, given in Java glob syntax"
},
"enum": {
"type": "array",
"description": "List of allowed values for the output channel",
"items": {
"type": ["string", "number", "boolean", "array", "object"]
},
"uniqueItems": true
}
},
"required": ["type", "description"]
}
}
"type": "object", "items": { "$ref": "#/definitions/elementProperties" }
}
},
"tools": {
Expand Down Expand Up @@ -160,6 +98,11 @@
"minItems": 1,
"uniqueItems": true,
"message": "Licence must be an array of one or more entries, e.g. [\"MIT\"]"
},
"identifier": {
"type": "string",
"description": "bio.tools identifier of the tool",
"pattern": "^biotools:.*$"
}
},
"required": ["description"],
Expand All @@ -182,5 +125,53 @@
}
}
},
"definitions": {
"elementProperties": {
"type": "object",
"patternProperties": {
".*": {
"type": "object",
"properties": {
"type": {
"type": "string",
"description": "Type of the channel element",
"enum": ["map", "file", "directory", "string", "integer", "float", "boolean", "list"]
mirpedrol marked this conversation as resolved.
Show resolved Hide resolved
},
"description": {
"type": "string",
"description": "Description of the channel"
},
"pattern": {
"type": "string",
"description": "Pattern of the channel, given in Java glob syntax"
},
"enum": {
"type": "array",
"description": "List of allowed values for the channel",
"items": {
"type": ["string", "number", "boolean", "array", "object"]
},
"uniqueItems": true
},
"ontologies": {
"type": "array",
"description": "List of ontologies for the channel",
"uniqueItems": true,
"items": {
"type": "object",
"patternProperties": {
".*": {
"type": "string",
"pattern": "^(http|https)://.*"
}
}
}
}
},
"required": ["type", "description"]
}
}
}
},
"required": ["name", "description", "keywords", "authors", "output", "tools"]
}