Token导航 LogoToken导航

Agent Skill · 前端设计

wordpress-plugin-dev(WordPress plugin DEV 命令行)

wordpress-plugin-dev 用于处理 GitHub 仓库、Issue、Pull Request 和代码协作信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要围绕仓库状态、代码变更或协作事项进行整理时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

wordpress-plugin-dev 是前端设计类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为接触敏感数据;许可证信息还不明确,第三方扫描已通过,按安装量在前端设计类的 10,216 个 Skill 里排第 8,536。

总安装 279周安装 12GitHub Stars 1下载 98核验 2026-05-01

安装说明

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

安装方式

通过对话安装

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

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

命令行安装

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

skills.shnpx skills
npx skills add https://github.com/alanef/plugin-fullworks-support-diagnostics-project --skill wordpress-plugin-dev

这个 Skill 是做什么的

前端设计类 Skill 关注页面结构、视觉规范和组件写法,输出通常是可运行的界面代码。

WordPress plugin DEV 命令行简化本地开发环境的搭建与调试流程。适用于快速初始化新插件、加载依赖和启动热重载服务。支持 npm scripts 集成和 Xdebug 配置,提升开发效率。配置文件可能包含敏感路径,请勿提交至公共代码仓库。

建议采用 Docker Compose 封装环境,保证跨平台一致性。

来源仓库内路径:skills/wordpress-plugin-dev

上手步骤

4 步
  1. 1

    确认自己的宿主工具

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

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/alanef/plugin-fullworks-support-diagnostics-pr…;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

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

  4. 4

    按最小权限试用

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

常见问题

6 条

wordpress-plugin-dev 怎么安装?

在终端执行 npx skills add https://github.com/alanef/plugin-fullworks-support-diagnostics-project --sk…。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

wordpress-plugin-dev 支持哪些 AI 工具?

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

wordpress-plugin-dev 需要什么权限?

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

wordpress-plugin-dev 是免费的吗?

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

wordpress-plugin-dev 用的人多吗?

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

wordpress-plugin-dev 安全吗?

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

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

值得选的地方

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

先想清楚的地方

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

适不适合你

更适合

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

不太适合

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

前端设计类 Skill 对比

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

前端设计 · Codex、Claude

8,823,360126,072只读MIT通过
vercel-composition-patterns

Vercel 组合模式 · Codex、Claude

3,858,81625,893需要联网MIT通过
vercel-react-native-skills

Vercel React native skills 前端 · Codex、Claude

2,468,66425,878只读MIT通过
adapt

adapt 搜索 · Codex、Claude

2,027,04023,125操作浏览器未明确通过
bolder

bolder 分析 · Codex、Claude

2,004,28823,130只读未明确通过
wordpress-plugin-dev

WordPress plugin DEV 命令行 · 本页

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

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

SKILL.md 原文

WordPress Plugin Development

Our Project Structure

We use a specific structure with a root project directory and nested plugin directory:

plugin-project-name/               # Root project directory
├── composer.json                  # Dev dependencies (phpcs, phpunit, phpstan)
├── phpcs.xml                      # WordPress-Extra ruleset
├── phpcs_sec.xml                  # Security-specific checks
├── phpstan.neon.dist              # Static analysis config
├── phpunit.xml.dist               # PHPUnit configuration
├── tests/                         # Tests at root level
│   ├── bootstrap.php              # PHPUnit bootstrap
│   ├── Unit/                      # Unit tests
│   └── Integration/               # Integration tests
├── vendor/                        # Composer dev dependencies
└── plugin-name/                   # Actual plugin directory
    ├── plugin-name.php            # Main plugin file
    ├── composer.json              # Plugin-specific dependencies
    ├── src/                       # Namespaced source code
    │   ├── Core/
    │   │   └── Main.php           # Main initialization class
    │   ├── Admin/
    │   │   └── AdminPage.php
    │   ├── Data/
    │   └── REST/
    │       └── DiagnosticsEndpoint.php
    ├── vendor/                    # Plugin dependencies
    ├── languages/                 # Translation files
    └── README.md

Key Points:

  • Root level has development tools (phpcs, phpunit, phpstan)
  • Plugin lives in subdirectory (e.g., fullworks-support-diagnostics/)
  • Use namespaced classes in src/ directory
  • Composer autoloading for both dev tools and plugin classes
  • Tests at root level, outside plugin directory
  • Separate composer.json for plugin distribution vs development

Main Plugin File Pattern

<?php
/**
 * Plugin Name: Your Plugin Name
 * Description: Brief description
 * Version: 1.0.0
 * Author: Your Name
 * License: GPL-2.0+
 * Text Domain: plugin-text-domain
 * Requires at least: 5.8
 * Requires PHP: 7.4
 */

// Prevent direct access
if (!defined('WPINC')) {
    die;
}

// Define plugin constants
define('PREFIX_PLUGIN_VERSION', '1.0.0');
define('PREFIX_PLUGIN_DIR', plugin_dir_path(__FILE__));
define('PREFIX_PLUGIN_URL', plugin_dir_url(__FILE__));

// Load Composer autoloader
require_once PREFIX_PLUGIN_DIR . 'vendor/autoload.php';

// Initialize the plugin
function prefix_initialize_plugin() {
    new \Vendor\PluginName\Core\Main();
}

add_action('plugins_loaded', 'prefix_initialize_plugin', 5);

Namespaced Class Structure

<?php
namespace Vendor\PluginName\Core;

use Vendor\PluginName\Admin\AdminPage;
use Vendor\PluginName\REST\DiagnosticsEndpoint;

class Main {
    const VERSION = '1.0.0';
    const OPTION_NAME = 'prefix_settings';

    private $settings;
    private $admin_page;

    public function __construct() {
        $this->settings = get_option(self::OPTION_NAME, []);
        $this->init_components();
        $this->setup_hooks();
    }

    private function init_components() {
        $this->admin_page = new AdminPage($this->settings);
    }

    private function setup_hooks() {
        add_action('admin_menu', [$this->admin_page, 'add_admin_menu']);
    }
}

WordPress Coding Standards (WPCS)

Code Style

  • Use tabs for indentation (not spaces)
  • Use proper PHPDoc blocks for all classes, methods, and functions
  • Follow WordPress naming conventions:

- Namespaced Classes: Vendor\PluginName\Feature\ClassName - Functions: prefix_function_name() - Files in src/: ClassName.php (matching class name)

  • Use Yoda conditions: if (true === $value)
  • Space after control structures: if (condition) {
  • Single quotes for strings unless variables or special characters needed

Our PHPCS Configuration

We use WordPress-Extra with custom exclusions:

<rule ref="WordPress-Extra">
    <exclude name="WordPress.Files.FileName.NotHyphenatedLowercase"/>
    <exclude name="Generic.WhiteSpace"/>
    <exclude name="PEAR.NamingConventions"/>
    <exclude name="Universal.Files.SeparateFunctionsFromOO"/>
    <exclude name="Universal.Operators.StrictComparisons"/>
</rule>

Run checks with:

composer phpcs        # Full WPCS check
composer check        # PHP compatibility + WPCS
composer phpcbf       # Auto-fix issues

Security Best Practices

Input Validation and Sanitization

  • Always sanitize input:

- sanitize_text_field() - general text - sanitize_email() - email addresses - sanitize_url() - URLs - absint() - positive integers - intval() - integers - wp_kses() / wp_kses_post() - HTML content

Output Escaping

  • Always escape output:

- esc_html() - HTML content - esc_attr() - HTML attributes - esc_url() - URLs - esc_js() - JavaScript strings - wp_kses_post() - Post content with safe HTML

Nonce Verification

// Creating nonce
wp_nonce_field( 'action_name', 'nonce_field_name' );

// Verifying nonce
if ( ! isset( $_POST['nonce_field_name'] ) ||
     ! wp_verify_nonce( $_POST['nonce_field_name'], 'action_name' ) ) {
    wp_die( 'Security check failed' );
}

Capability Checks

if ( ! current_user_can( 'manage_options' ) ) {
    wp_die( 'Unauthorized access' );
}

SQL Security

  • Use $wpdb->prepare() for all SQL queries
  • Never concatenate user input into SQL
$wpdb->get_results( $wpdb->prepare(
    "SELECT * FROM {$wpdb->prefix}table WHERE id = %d AND name = %s",
    $id,
    $name
) );

WordPress Hooks System

Actions vs Filters

  • Actions: Execute code at specific points (side effects)
  • Filters: Modify data before returning

Best Practices

// Use unique prefixes to avoid conflicts
add_action( 'init', 'prefix_init_function' );
add_filter( 'the_content', 'prefix_modify_content', 10, 1 );

// Always specify priority (default: 10) and accepted args
add_action( 'save_post', 'prefix_save_post_action', 10, 2 );

// Remove actions/filters when needed
remove_action( 'init', 'prefix_init_function' );

Hook Timing

  • plugins_loaded - After plugins loaded
  • init - Initialize plugin features
  • admin_init - Admin-specific initialization
  • wp_enqueue_scripts - Enqueue frontend assets
  • admin_enqueue_scripts - Enqueue admin assets

Database Operations

Options API

// Get option with default
$value = get_option( 'prefix_option_name', 'default_value' );

// Update option
update_option( 'prefix_option_name', $value );

// Autoload consideration
add_option( 'prefix_option_name', $value, '', 'no' ); // Don't autoload

Custom Tables

  • Use $wpdb->prefix for table names
  • Create tables on plugin activation with dbDelta()
  • Include charset and collation

Internationalization (i18n)

// Text domain should match plugin slug
__( 'Text to translate', 'plugin-text-domain' );
_e( 'Text to echo', 'plugin-text-domain' );
esc_html__( 'Text to translate and escape', 'plugin-text-domain' );
esc_html_e( 'Text to echo and escape', 'plugin-text-domain' );

// With variables
sprintf(
    /* translators: %s: user name */
    __( 'Hello, %s!', 'plugin-text-domain' ),
    $user_name
);

REST API

add_action( 'rest_api_init', 'prefix_register_routes' );

function prefix_register_routes() {
    register_rest_route( 'plugin/v1', '/endpoint', array(
        'methods'             => 'POST',
        'callback'            => 'prefix_endpoint_callback',
        'permission_callback' => 'prefix_permission_check',
    ) );
}

Error Handling

// Use WP_Error for error handling
if ( is_wp_error( $result ) ) {
    return $result;
}

// Create errors
return new WP_Error( 'error_code', __( 'Error message', 'text-domain' ) );

Performance Optimization

  • Use transients for caching: set_transient(), get_transient()
  • Lazy load when possible
  • Minimize database queries
  • Use wp_cache_* functions for object caching
  • Enqueue minified assets in production

Testing with wp-env

We use @wordpress/env (wp-env) for local development and testing:

Setup

# Install wp-env globally (if not already installed)
npm -g install @wordpress/env

# Start WordPress environment
wp-env start

# Stop environment
wp-env stop

# Clean/reset environment
wp-env clean

Running Tests

# Set up test environment variable
export WP_PHPUNIT__TESTS_CONFIG=/path/to/wp-tests-config.php

# Run PHPUnit tests
composer test

# Or run directly with wp-env
wp-env run tests-cli --env-cwd=wp-content/plugins/plugin-name vendor/bin/phpunit

PHPUnit Configuration

Our phpunit.xml.dist defines two test suites:

  • unit: Unit tests in tests/Unit/ (no WordPress dependencies)
  • integration: Integration tests in tests/Integration/ (with WordPress)

Test Bootstrap

The tests/bootstrap.php file:

  • Loads Composer autoloader
  • Checks for WP_PHPUNIT__TESTS_CONFIG environment variable
  • Requires WordPress test configuration

Writing Tests

<?php
namespace Tests\Unit;

use PHPUnit\Framework\TestCase;
use Yoast\PHPUnitPolyfills\Polyfills\AssertEqualsCanonicalizing;

class SampleTest extends TestCase {
    use AssertEqualsCanonicalizing;

    public function test_sample() {
        $this->assertTrue(true);
    }
}

Static Analysis

PHPStan

composer phpstan      # Run static analysis

Configuration in phpstan.neon.dist with WordPress-specific rules via szepeviktor/phpstan-wordpress.

Build and Distribution

Building Plugin

composer build

This will:

  1. Clean zipped directory
  2. Install production dependencies in plugin directory
  3. Create zip file in zipped/ directory

Composer Scripts

  • composer phpcs - Run coding standards check
  • composer check - Run PHP compatibility checks (7.4-8.3) + WPCS
  • composer phpcbf - Auto-fix coding standards issues
  • composer phpstan - Run static analysis
  • composer test - Run PHPUnit tests
  • composer build - Build distribution zip

Testing Checklist

  • All tests pass (composer test)
  • No coding standards violations (composer check)
  • No static analysis errors (composer phpstan)
  • Test in wp-env with WP_DEBUG enabled
  • Test with multiple PHP versions (7.4-8.3)
  • Verify compatibility with latest WordPress version
  • Check that plugin works after building (composer build)

平台分布

Codex

39.34%
按下载量换算39

Claude

28.47%
按下载量换算28

Cursor

17.47%
按下载量换算17

Gemini CLI

10.52%
按下载量换算10

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

接触敏感数据

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

安装前确认

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

继续浏览同类 Skills