Create Plugin Scaffold

作者 cursorccb5507cec15無授權條款10K 個星標收錄於 2026年10月8日更新於 2026年10月8日儲存庫今天更新

Create a new Cursor plugin scaffold with a valid manifest, component directories, and marketplace wiring. Use when starting a new plugin or adding a plugin to a multi-plugin repository.

僅含說明AI & Agents
AI 產生的概覽

為新的 Cursor 外掛建立骨架,包含資訊清單、元件檔案與可選的市集項目。

功能
引導建立新的 Cursor 外掛目錄,其中包含 plugin.json 資訊清單、README、LICENSE 以及可選的 CHANGELOG。它會為規則、技能、代理、指令、鉤子或 MCP 伺服器建立帶有有效 frontmatter 的元件檔案,並在儲存庫為多外掛市集時加入 marketplace.json 項目。最後輸出建立的檔案樹、最終資訊清單以及簡短的驗證報告。
適用情境
適用於從零開始建立新的 Cursor 外掛,或將外掛加入既有的多外掛市集儲存庫。適合需要有效資訊清單與元件目錄結構、以便本機使用或提交至市集的情境。
執行需求
不包含指令碼,僅為說明文件。它假定存在 Cursor 外掛環境與本機外掛目錄,並且在進行市集設定時需要既有的 marketplace.json。

Create plugin scaffold

Trigger

You need to create a new Cursor plugin from scratch and make it ready for local use or marketplace submission.

Required Inputs

  • Plugin name (lowercase kebab-case)
  • Plugin purpose and target users
  • Component set to include (rules, skills, agents, commands, hooks, mcpServers)
  • Repository style (single-plugin or multi-plugin marketplace)

Output Location

By default, create the plugin inside the user's local plugin directory:

~/.cursor/plugins/local/<plugin-name>/

This path makes the plugin immediately available to Cursor without any install step. If the user explicitly asks to create the plugin elsewhere (e.g. inside an existing repo or a specific directory), respect that choice instead.

Workflow

  1. Validate plugin name format: lowercase kebab-case, starts and ends with an alphanumeric character.
  2. Determine the target directory:
    • Default: ~/.cursor/plugins/local/<plugin-name>/
    • Override: use the path the user specifies, if any.
    • Create the directory (and parents) if it does not exist.
  3. Create base files inside the target directory:
    • .cursor-plugin/plugin.json
    • README.md
    • LICENSE
    • optional CHANGELOG.md
  4. Populate plugin.json:
    • Required: name
    • Recommended: version, description, author, license, keywords
    • Add explicit component paths only when non-default discovery is needed.
  5. Create component files with valid frontmatter:
    • Rules: .mdc with description, alwaysApply, optional globs
    • Skills: skills/<skill-name>/SKILL.md with name, description
    • Agents: agents/*.md with name, description
    • Commands: commands/*.(md|txt) with name, description
  6. If repository uses .cursor-plugin/marketplace.json, add plugin entry:
    • name
    • source
    • optional metadata (description, keywords, category, tags)
  7. Ensure all manifest paths are relative, valid, and do not use absolute paths or parent traversal.

Guardrails

  • Keep the plugin focused on one use case.
  • Prefer concise, actionable skill and rule text over long prose.
  • Do not reference files that do not exist.
  • Use folder discovery defaults unless custom paths are required.
  • Always save to ~/.cursor/plugins/local/<plugin-name>/ unless the user provides a different path.

Output

  • Created file tree for the plugin (with full path to the output directory)
  • Final plugin.json
  • Marketplace entry (if applicable)
  • Short validation report of required fields and component metadata
  • Confirmation that the plugin is saved under ~/.cursor/plugins/local/ and ready for use

來源與署名

來源:cursor/plugins位於create-plugin/skills/create-plugin-scaffold提交ccb5507

授權條款: 無授權條款

內容歸原作者所有。SourceWeft 從公開儲存庫中收錄這些內容。

檢舉或申請下架