Skip to main content

How to use plugin-template

Serves as a template for creating new DSH plugins, offering a scaffold for development.

This article is auto-derived from indexed fields (wiki / faq / compatibility_json), not freshly AI-generated.

This article is derived from the plugin's already-indexed fields (wiki / faq / compatibility_json / readme), not freshly generated by AI. Source field is noted at the end of each section.

Quick start

Serves as a template for creating new DSH plugins, offering a scaffold for development.

— source: plugins.ai_summary

Install & verify

dsh plugin --profile web add --allow-build=@your-scope/dsh-plugin-template github:omdsh-dev/dsh-mygo#path:packages/cordis/mygo-cli/assets/plugin-template

Run the command above in your DSH Web Profile. Then enable the plugin in the plugin list.

— source: plugins.install

Key points

  • 核心(packages/cordis/mygo):manifest/求解/锁定/存储/校验/政策闸/报告/
  • 契约层(packages/core/mygo-api):Cordis-free 的插件作者面
    • packages/cordis/mygo-cli —— 用户命令面(pack/restore/init),本身是 mygo 受管插件;
    • vendor/dsh-mygo-panel —— web 设置页「My 插件」面板(settings.section 槽 + /api/mygo/*);
    • extension/mygo-rdb —— 外部注册表存储(sqlite/postgres,RegistryStore 契约);

— source: plugin_wiki.readme_en (fallback readme_raw)

Pitfalls

Review the upstream repo before installing. This guide is auto-derived from indexed fields and may lag the latest release. If anything contradicts the official docs, treat the upstream source as authoritative.

— source: general rule