feat(schema): refine and expand extension metadata schema

- Introduce `scope`, `tags`, `min_version`, `homepage`, and `installation` fields for enhanced discoverability and guidance.
- Remove `install` and `compatibility` objects, replacing them with a simplified `installation` string field.
- Add `examples/` directory with full exemplar files for each extension type.
- Update `schema-design.md` to reflect new schema, clarify field definitions, and improve documentation structure.
This commit is contained in:
Lucas Shamanic 2026-01-12 23:47:06 +00:00
parent 8f1acd2c7c
commit a806755d0f
9 changed files with 697 additions and 559 deletions

View file

@ -8,64 +8,56 @@
"name": {
"type": "string",
"minLength": 1,
"description": "Name of the project or tool"
"description": "Display name of the project or tool"
},
"repo": {
"type": "string",
"format": "uri",
"description": "URL to the repository"
"description": "URL to the repository (https://github.com/...)"
},
"tagline": {
"tagline": {
"type": "string",
"minLength": 1,
"maxLength": 120,
"description": "Short punchy summary of the project (shown in collapsed view)"
"description": "Short punchy summary (shown in collapsed view)"
},
"description": {
"type": "string",
"minLength": 1,
"description": "Full description of the project (shown when expanded)"
},
"install": {
"type": "object",
"description": "Installation instructions",
"properties": {
"type": {
"type": "string",
"enum": ["config", "npm", "pip", "go", "script", "manual"],
"description": "Type of installation method"
}
"scope": {
"type": "array",
"items": {
"type": "string",
"enum": ["global", "project"]
},
"required": ["type"],
"additionalProperties": false
},
"compatibility": {
"type": "object",
"description": "Compatibility information",
"properties": {
"platforms": {
"type": "array",
"items": {
"type": "string"
},
"description": "Supported platforms"
},
"opencode": {
"type": "string",
"description": "Compatible Opencode version"
}
},
"required": ["platforms", "opencode"],
"additionalProperties": false
"minItems": 1,
"uniqueItems": true,
"description": "Installation scope: global (~/.config/opencode/) or project (.opencode/). Defaults to [global] if omitted."
},
"tags": {
"type": "array",
"items": {
"type": "string"
},
"description": "Tags for categorization"
"description": "Tags for filtering and discoverability"
},
"min_version": {
"type": "string",
"pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+",
"description": "Minimum OpenCode version required (semver format, e.g. '1.0.0')"
},
"homepage": {
"type": "string",
"format": "uri",
"description": "Documentation URL if different from repository"
},
"installation": {
"type": "string",
"description": "Detailed installation instructions in markdown format"
}
},
"required": ["name", "repo", "tagline", "description"],
"additionalProperties": false
"additionalProperties": true
}