Token导航 LogoToken导航

Agent Skill · 研究检索

craftcms(craftcms 搜索)

craftcms 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

craftcms 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为接触敏感数据;许可证信息还不明确,第三方扫描已通过,按安装量在研究检索类的 73,675 个 Skill 里排第 64,068。

总安装 306周安装 13GitHub Stars 38下载 107核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:craftcms(craftcms 搜索)
来源仓库:https://github.com/michtio/craftcms-claude-skills
仓库路径:skills/craftcms
安装命令:
npx skills add https://github.com/michtio/craftcms-claude-skills --skill craftcms
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/michtio/craftcms-claude-skills --skill craftcms

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

用于查找、检索和筛选相关信息,适合关键词驱动的任务场景。可根据任务线索快速定位候选结果,需明确搜索目标和来源范围。安装前建议确认权限和维护状态,避免触发未预期的联网或数据访问。通过 npx 命令从指定仓库安装,适用于 Codex、Claude、Cursor 等宿主环境。

实际用法需参考原始 README 和 SKILL.md,确保理解其检索逻辑和输出格式。

来源仓库内路径:skills/craftcms

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/michtio/craftcms-claude-skills --skill craftcm…;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要接触敏感数据,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

craftcms 怎么安装?

在终端执行 npx skills add https://github.com/michtio/craftcms-claude-skills --skill craftcms。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

craftcms 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

craftcms 需要什么权限?

权限级别是接触敏感数据。该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

craftcms 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

craftcms 用的人多吗?

公开数据是累计安装 306 次,近一周安装 13 次,下载 107 次,GitHub 38 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

craftcms 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 第三方扫描已通过,常见的高风险行为没有命中。

先想清楚的地方

  • 需要接触敏感数据,装到常用环境前要先评估影响面。
  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 环境里有大量密钥、凭证,不方便给第三方 Skill 读取的人。
  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
craftcms

craftcms 搜索 · 本页

30638接触敏感数据未明确通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Craft CMS 5 — Extending (Plugins & Modules)

Reference for extending Craft CMS 5 through plugins and modules. Covers everything from elements and services to controllers, migrations, fields, and events.

This skill is scoped to extending Craft — building plugins, modules, custom element types, field types, and backend integrations. For site/platform development (content modeling, sections, entry types, Twig templating, plugin selection), see the craft-site skill.

Companion Skills — Always Load Together

When this skill triggers, also load:

  • craft-php-guidelines — PHPDoc standards, section headers, naming conventions, class organization, ECS/PHPStan, verification checklist. Required for any PHP code.
  • ddev — All commands run through DDEV. Required for running ECS, PHPStan, scaffolding, and tests.
  • craft-garnish — When working on CP JavaScript, asset bundles, or interactive CP components. Covers Garnish's class system, UI widgets (Modal, HUD, DisclosureMenu, Select), drag system, and the Craft.* JS class pattern.

Documentation

Use WebFetch on specific doc pages when a reference file doesn't cover enough detail.

Common Pitfalls (Cross-Cutting)

  • Always use addSelect() in beforePrepare() — it's the Craft convention and safely additive when multiple extensions contribute columns.
  • Queue workers run in primary site context — use ->site('*') for cross-site queries.
  • Including id in getConfig() — project config uses UIDs, never database IDs.
  • Business logic in models or controllers — services are where logic belongs.
  • Modules need manual template root, translation, and controllerNamespace registration — nothing is automatic.
  • DateTimeHelper in elements/queries, Carbon in services — never mix in the same class.

Reference Files

Read the relevant reference file(s) for your task. Multiple files often apply together.

Task examples:

  • "Build a custom element type" → read elements.md + element-index.md + fields.md + migrations.md + cp.md
  • "Add a webhook endpoint" → read controllers.md + events.md
  • "Create a queue job that syncs elements" → read queue-jobs.md + elements.md + debugging.md
  • "Add a settings page with form fields" → read controllers.md + cp.md + architecture.md
  • "Register a custom field type" → read fields.md + events.md
  • "Fix PHPStan errors" → read quality.md
  • "Add a dashboard widget" → read cp.md (Dashboard Widgets) + events.md (Widget Types section)
  • "Expose template variables for plugin users" → read events.md (Twig Extensions section)
  • "Attach custom methods to entries" → read events.md (Behaviors section)
  • "Build a CP utility page" → read events.md (Utilities section) + cp.md
  • "Set up Vite for a plugin's CP assets" → read plugin-vite.md + load craft-garnish skill
  • "Add drag-to-reorder or interactive JS to a CP page" → load craft-garnish skill
  • "Write CP JavaScript for a custom field type" → read fields.md + load craft-garnish skill
  • "Build a headless Craft API" → read graphql.md + load craft-site skill for headless.md
  • "Configure preview for a Next.js front-end" → load craft-site skill for headless.md
  • "Set up Pest tests for a plugin" → read testing.md
  • "Write a test for a controller action" → read testing.md
  • "Configure Redis for caching and sessions" → read config-app.md
  • "Set up environment variables for production" → read config-bootstrap.md
  • "Find a GeneralConfig setting" → read config-general.md
  • "Configure mail transport / SMTP" → read config-app.md
  • "Set up custom URL routes" → read config-bootstrap.md
  • "Configure search to find short words" → read config-app.md
  • "Set up GraphQL tokens and schemas" → read graphql.md + config-general.md
  • "Set up caching for a high-traffic site" → read caching.md
  • "Register custom permissions for my plugin" → read permissions.md
  • "Check user permissions in templates" → read permissions.md
  • "Set up plugin editions / feature gating" → read architecture.md (Plugin Editions section)
  • "Upgrade a plugin from Craft 4 to 5" → read quality.md (Rector section)
  • "Set up CI for a Craft plugin" → read quality.md (CI/CD Integration section)
  • "Create sections or fields in a migration" → read migrations.md (Content Migrations section)
  • "Set up database read replicas" → read config-app.md (Database Replicas section)
  • "Register a module in app.php" → read config-app.md (Module Registration section)
  • "Create a custom validator" → read architecture.md (Custom Validators section)
  • "Create a custom filesystem type" → read events.md (Filesystem Types section)
  • "Build a custom condition rule for an element index" → read cp.md (Condition Builders section)
  • "Set up pre-commit hooks for code quality" → read quality.md (Pre-Commit Hooks section)
  • "Restrict element access by user group" → read element-authorization.md + permissions.md
  • "Scope CP element index by permission" → read element-authorization.md (Layer 3: Query Scoping)
  • "Add authorization events to a custom element" → read element-authorization.md + elements.md
  • "Build defense-in-depth for a security plugin" → read element-authorization.md (Defense Patterns)
  • "Force-logout a user from all devices" → read sessions-and-auth.md (Plugin Patterns)
  • "Understand how Craft sessions work" → read sessions-and-auth.md
  • "Implement password reset required" → read sessions-and-auth.md (passwordResetRequired Gap)
  • "Add a column to the Users element index" → read element-index.md (Extending Element Indexes via Events)
  • "Add a bulk action to an element index" → read element-index.md (Adding a custom bulk action)
  • "Add a custom sidebar source to the element index" → read element-index.md (Adding a sidebar source)
  • "Build a custom field type" → read field-types-custom.md + fields.md
  • "Build a relation field type" → read field-types-custom.md (Relation Fields)
  • "Add a condition rule to the entry index" → read conditions.md + element-index.md
  • "Build a custom condition rule" → read conditions.md
  • "Send email from a plugin" → read email.md
  • "Register a custom system message" → read email.md (Registering Custom System Messages)
  • "Configure SMTP transport" → read config-app.md + email.md
  • "Deploy Craft CMS to production" → read deployment.md
  • "Set up CI/CD for a Craft project" → read deployment.md (CI/CD Patterns)
  • "Zero-downtime deploy" → read deployment.md (Zero-Downtime)
  • "Roll back a failed deploy" → read deployment.md (Rollback Strategies)
  • "Work with drafts and revisions" → read drafts-revisions.md
  • "Create a draft programmatically" → read drafts-revisions.md (Creating Drafts)
  • "Skip side effects for drafts in afterSave" → read drafts-revisions.md (Plugin Considerations)
TaskRead
Element core: lifecycle, queries, status, authorization, drafts, revisions, propagation, field layouts, eventsreferences/elements.md
Element index: sources, table/card attributes, sort, conditions, actions, exporters, sidebar, metadata, extending via events (columns, sources, bulk actions, condition rules, sort)references/element-index.md
Services, models, records, project config, MemoizableArray, events, API clients, custom validatorsreferences/architecture.md
Controllers: CP CRUD, webhooks, API endpoints, action routing, authorizationreferences/controllers.md
CP templates, form macros, admin changes, VueAdminTable, asset bundles, CP layout, permissions. For CP JavaScript interactions, also load craft-garnish skill.references/cp.md
Database migrations, Install.php, foreign keys, indexes, idempotency, deploymentreferences/migrations.md
Queue jobs, BaseJob, TTR, retry, progress, batch jobs, site contextreferences/queue-jobs.md
Console commands, arguments, options, progress bars, output helpers, resave actionsreferences/console-commands.md
Debugging, performance, query strategy, profiling, Xdebug, caching, loggingreferences/debugging.md
PHPStan, ECS, code review checklistreferences/quality.md
Testing: Pest setup, element factories, HTTP/queue/DB assertions, mocking, multi-site, console, eventsreferences/testing.md
Field types, native fields, BaseNativeField, field layout elements, FieldLayoutBehaviorreferences/fields.md
Events: registration, lifecycle, naming conventions, custom events, behaviors, Twig extensions, utilities, widgets, filesystems, discovering eventsreferences/events.md
GraphQL types, queries, mutations, directives, schema components, resolversreferences/graphql.md
Plugin Vite: VitePluginService, CP asset bundles, HMR, TypeScript, Vue in CPreferences/plugin-vite.md
Headless & hybrid: headlessMode, GraphQL API, CORS, preview tokens, front-end frameworkscraft-site skill references/headless.md
GeneralConfig (system, routing, security, users, sessions, search, assets, images)references/config-general.md
GeneralConfig (content, templates, performance, GC, localization, headless, GraphQL, accessibility, preview, dev, dangerous interactions)references/config-general-extended.md
App config: cache, session, queue, mutex, mailer/SMTP, search, logging, CORS, DB replicas, web/console splitreferences/config-app.md
Config bootstrap: env vars, aliases, priority order, fluent API, custom.php, db.php, routes.php, htmlpurifierreferences/config-bootstrap.md
Caching: template cache tag, data cache, static caching (Blitz), CDN, layered strategy, invalidationreferences/caching.md
Permissions: built-in handles, user groups, custom registration, Twig/PHP checking, authorization events, strategiesreferences/permissions.md
Element authorization: four-layer defense model, authorization events, can*() methods, EVENT_BEFORE_PREPARE query scoping, controller enforcementreferences/element-authorization.md
Sessions & auth internals: dual-layer session model, auth tokens, session invalidation, passwordResetRequired, elevated sessions, plugin patternsreferences/sessions-and-auth.md
Custom field types: build pattern, value lifecycle, settings, input HTML, validation, search, GraphQL, relation fieldsreferences/field-types-custom.md
Conditions framework: BaseCondition, ElementCondition, custom condition rules, registering rules, condition builder UIreferences/conditions.md
Email system: system messages, custom messages, programmatic sending, templates, events, testingreferences/email.md
Deployment: standard pipeline, project config deploy, zero-downtime, CI/CD, rollback, environment managementreferences/deployment.md
Drafts & revisions: draft types, provisional drafts, autosave, applying, merge, revisions, plugin considerationsreferences/drafts-revisions.md

Plugin vs Module Differences

Plugins and modules share the same architecture patterns. The differences are in bootstrapping and registration:

FeaturePluginModule
CP template rootAutomatic (by handle)Manual via EVENT_REGISTER_CP_TEMPLATE_ROOTS
Site template rootManual via eventSame — manual for both
Translation categoryAutomatic (by handle)Manual PhpMessageSource in init()
Settings modelBuilt-in createSettingsModel()Env vars, config files, or private plugin (_ prefix)
Install migrationmigrations/Install.phpContent migrations only
Console commandsAutomatic controllerNamespaceMust set before parent::init(), must be bootstrapped
CP nav section$hasCpSection = trueEVENT_REGISTER_CP_NAV_ITEMS
Project configSettings auto-trackedManual ProjectConfig::set() only
Namespace aliasAutomatic via ComposerMust call Craft::setAlias()

Module Template Root Registration

use craft\events\RegisterTemplateRootsEvent;
use craft\web\View;

Event::on(View::class, View::EVENT_REGISTER_CP_TEMPLATE_ROOTS,
    function(RegisterTemplateRootsEvent $event) {
        $event->roots['my-module'] = __DIR__ . '/templates';
    }
);

Module Translation Registration

Craft::$app->i18n->translations['my-module'] = [
    'class' => \craft\i18n\PhpMessageSource::class,
    'sourceLanguage' => 'en',
    'basePath' => __DIR__ . '/translations',
    'allowOverrides' => true,
];

Module Console Command Registration

public function init()
{
    Craft::setAlias('@mymodule', __DIR__);

    if (Craft::$app->getRequest()->getIsConsoleRequest()) {
        $this->controllerNamespace = 'modules\\mymodule\\console\\controllers';
    } else {
        $this->controllerNamespace = 'modules\\mymodule\\controllers';
    }

    parent::init(); // MUST come after setting controllerNamespace
}

The module must be bootstrapped in config/app.php for console commands to be discoverable.

平台分布

Codex

37.48%
按下载量换算40

Claude

30.12%
按下载量换算32

Cursor

19.91%
按下载量换算21

Gemini CLI

9.55%
按下载量换算10

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

接触敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills