@wporg/plugin-check 0.1.0 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +41 -0
  2. package/package.json +3 -2
package/README.md ADDED
@@ -0,0 +1,41 @@
1
+ # @wporg/plugin-check
2
+
3
+ Run [WordPress Plugin Check](https://wordpress.org/plugins/plugin-check/) locally via [WordPress Playground CLI](https://wordpress.github.io/wordpress-playground/developers/local-development/wp-playground-cli/). Requires only Node.js (v20+).
4
+
5
+ ## Usage
6
+
7
+ ```bash
8
+ npx @wporg/plugin-check ./my-plugin
9
+ npx @wporg/plugin-check ./my-plugin.zip
10
+ npx @wporg/plugin-check https://example.com/my-plugin.zip
11
+ ```
12
+
13
+ Accepts a local plugin directory, a local zip file, or a remote zip URL.
14
+
15
+ ## Output
16
+
17
+ Results are printed to stdout in Plugin Check's JSON format, grouped by file:
18
+
19
+ ```
20
+ FILE: example.php
21
+ [{"line":1,"column":0,"type":"ERROR","code":"code_id","message":"Description","docs":"https://..."}]
22
+ ```
23
+
24
+ Empty output (exit code 0) means the plugin passed all checks.
25
+
26
+ Exit code 1 means errors were found.
27
+
28
+ ## What it checks
29
+
30
+ Runs the same checks WordPress.org uses during plugin submission review:
31
+
32
+ - `--categories=plugin_repo`
33
+ - `--format=json`
34
+ - `--error-severity=7`
35
+ - `--warning-severity=6`
36
+ - `--include-low-severity-errors`
37
+ - `--exclude-checks=prefixing`
38
+
39
+ ## License
40
+
41
+ GPL-2.0-or-later
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wporg/plugin-check",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "Run WordPress Plugin Check locally via Playground CLI.",
5
5
  "type": "module",
6
6
  "license": "GPL-2.0-or-later",
@@ -8,7 +8,8 @@
8
8
  "plugin-check": "bin/plugin-check.mjs"
9
9
  },
10
10
  "files": [
11
- "bin/plugin-check.mjs"
11
+ "bin/plugin-check.mjs",
12
+ "README.md"
12
13
  ],
13
14
  "scripts": {
14
15
  "test": "node --test test/*.test.mjs"