{"id":13564760,"url":"https://github.com/abiosoft/caddy-json-schema","last_synced_at":"2025-03-17T03:31:10.225Z","repository":{"id":38439666,"uuid":"266081179","full_name":"abiosoft/caddy-json-schema","owner":"abiosoft","description":"JSON schema generator for Caddy v2","archived":false,"fork":false,"pushed_at":"2022-06-21T03:19:27.000Z","size":5252,"stargazers_count":140,"open_issues_count":4,"forks_count":3,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-16T07:41:34.438Z","etag":null,"topics":["caddy","caddy-module","caddy-plugin","caddyserver","intellisense","json","json-schema"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/abiosoft.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-05-22T10:17:38.000Z","updated_at":"2025-03-10T02:21:24.000Z","dependencies_parsed_at":"2022-09-06T08:10:36.072Z","dependency_job_id":null,"html_url":"https://github.com/abiosoft/caddy-json-schema","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abiosoft%2Fcaddy-json-schema","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abiosoft%2Fcaddy-json-schema/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abiosoft%2Fcaddy-json-schema/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abiosoft%2Fcaddy-json-schema/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/abiosoft","download_url":"https://codeload.github.com/abiosoft/caddy-json-schema/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243968828,"owners_count":20376454,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["caddy","caddy-module","caddy-plugin","caddyserver","intellisense","json","json-schema"],"created_at":"2024-08-01T13:01:35.520Z","updated_at":"2025-03-17T03:31:09.841Z","avatar_url":"https://github.com/abiosoft.png","language":"Go","funding_links":[],"categories":["Go"],"sub_categories":[],"readme":"# caddy-json-schema\n\nJSON schema generator for Caddy v2.\n\nThe generated schema can be integrated with editors for intellisense and better experience with configuration and plugin development.\n\n![Demonstration](https://github.com/abiosoft/caddy-json-schema/blob/master/gif/schema.gif)\n\n## Installation\n\nThe generated schema is for the caddy binary. i.e. all modules in the binary will\nbe include in the schema.\n\n```sh\nxcaddy build v2.4.1 \\\n    --with github.com/abiosoft/caddy-json-schema \\\n    # any other module you want to include in the generated schema\n```\n\n## Usage\n\nRun `caddy help json-schema` to view help.\n\n```\nusage:\n  caddy json-schema [--output \u003cfile\u003e] [--indent \u003cint\u003e] [--vscode] [--no-cache]\n\nflags:\n  -indent int\n        Number of spaces to indent the generated JSON with (default 2)\n  -no-cache\n        Discard local cache and fetch latest API docs\n  -output string\n        The file to write the generated schema (default \"./caddy_schema.json\")\n  -vscode\n        Generate VSCode configuration\n```\n\n## Editors\n\n### Visual Studio Code\n\n`caddy json-schema --vscode` generates Visual Studio Code configuration in the current directory.\n\nOpen the directory in Visual Studio Code and it should just work.\nEnsure the config filename is of the format `*caddy*.[json|yaml]`.\n\n**Note** that you need [vscode-yaml](https://marketplace.visualstudio.com/items?itemName=redhat.vscode-yaml) plugin to get similar experience for YAML files.\n\n### Vim/NeoVim\n\nThere are multiple Vim/NeoVim plugins with language server and JSON schema support.\n\nBelow is a config for [coc-json](https://github.com/neoclide/coc-json) and [coc-yaml](https://github.com/neoclide/coc-yaml). The path to schema file is relative to the config file being edited.\n\n```json\n{\n  \"json.schemas\": [\n    {\n      \"fileMatch\": [\"*caddy*.json\"],\n      \"url\": \"./caddy_schema.json\"\n    }\n  ],\n  \"yaml.schemas\": {\n    \".vscode/caddy_schema.json\": [\"*caddy*.yaml\", \"*caddy*.yml\"]\n  }\n}\n```\n\n## Features\n\n| Modules     | Intellisense | Documentation                                          |\n| ----------- | ------------ | ------------------------------------------------------ |\n| Standard    | Supported    | Supported                                              |\n| Third Party | Supported    | Supported (if plugin is registered on caddyserver.com) |\n\n## License\n\nApache 2\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabiosoft%2Fcaddy-json-schema","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fabiosoft%2Fcaddy-json-schema","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabiosoft%2Fcaddy-json-schema/lists"}