WordPress / plugin-check
A repository for the new Plugin Check plugin from the WordPress Performance and Plugins Team.
View on GitHubAI Architecture Analysis
This repository is indexed by RepoMind. By analyzing WordPress/plugin-check in our AI interface, you can instantly generate complete architecture diagrams, visualize control flows, and perform automated security audits across the entire codebase.
Our Agentic Context Augmented Generation (Agentic CAG) engine loads full source files into context on-demand, avoiding the fragmentation of traditional RAG systems. Ask questions about the architecture, dependencies, or specific features to see it in action.
Repository Overview (README excerpt)
Crawler viewPlugin Check Plugin Check is a WordPress.org tool which provides checks to help plugins meet the directory requirements and follow various best practices. Features For end users • Allows analyzing any installed plugin using either a WP Admin screen or a WP-CLI command. • Supports two kinds of checks: • Static checks, which analyze the code, either using PHPCodeSniffer sniffs or custom logic e.g. using regular expressions. • Runtime checks, which actually execute certain parts of the code, such as running specific WordPress hooks with the plugin active. • Allows customizing which checks are run, either via a list of individual check identifiers, or specific check categories. • Comes with an ever-growing list of checks for various plugin development requirements and best practices. Please see the method for a quick overview of currently available checks. For developers • Facilitates efficient yet flexible authoring of new checks, either using a base class for common check patterns, or implementing an interface for more specific checks. • Every check has to implement either the or the interface. • Most checks will benefit from extending either the , the , or the class. • Comes with comprehensive unit test coverage. How to use The WordPress plugin checker is a WordPress plugin itself, which can be installed on any WordPress site. While it is implemented in a way that should avoid any disruptions on the site that it is being used on, it is still **advised not to use the plugin checker in a production environment**. There are a few ways to install the plugin checker: • Search for "Plugin Check (PCP)" on the page to install plugins ( ) on your WP site. • Download it from the WP.org plugins repository: https://wordpress.org/plugins/plugin-check/ • Clone this repository. See the contributing section below for further instructions. After having the plugin activated, you can analyze any other plugin installed on the same site, either using the WP Admin user interface or WP-CLI: • To check a plugin using WP Admin, please navigate to the _Tools > Plugin Check_ menu. You need to be able to manage plugins on your site in order to access that screen. • To check a plugin using WP-CLI, please use the command. For example, to check the "Hello Dolly" plugin: • Note that by default when using WP-CLI, only static checks can be executed. In order to also include runtime checks, a workaround is currently necessary using the argument of WP-CLI, to manually load the file within the plugin checker directory before WordPress is loaded. For example: • You could use arbitrary path or URL to check a plugin. For example, to check a plugin from a URL: or to check a plugin from a path: Screenshot of the plugin checker's UI in WP Admin Contributing To set up the repository locally, you will need to clone this GitHub repository (or a fork of it) and then install the relevant dependencies: Built-in development environment (optional) With the above commands, you can use the plugin in any development environment as you like. The recommended way is to use the built-in development environment, which is based on the package, as that will allow you to use the preconfigured commands to e.g. run unit tests, linting etc. You will need to have Docker installed to use this environment. You can start the built-in environment as follows: If you want to stop the environment again, you can use: For further information on contributing, please see the contributing guide. Technical documentation To learn more about the functionality and technical details of the WordPress plugin checker, please refer to the technical documentation. License The WordPress plugin checker is free software, and is released under the terms of the GNU General Public License version 2 or (at your option) any later version. See LICENSE for complete license.