Skip to content

Commit 0672d8b

Browse files
committed
Added Tools
Composer, Package and PHPStan
1 parent db21595 commit 0672d8b

File tree

4 files changed

+75
-4
lines changed

4 files changed

+75
-4
lines changed

composer.json

Lines changed: 20 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "webberzone/knowledgebase",
3-
"description": "Quickly and efficiently create a highly-flexible knowledge base or FAQ on your WordPress blog.",
3+
"description": "Fastest way to create a highly-flexible multi-product knowledge base.",
44
"type": "wordpress-plugin",
55
"keywords": [
66
"knowledge base",
@@ -10,15 +10,31 @@
1010
"support",
1111
"documentation"
1212
],
13-
"license": "gpl-2.0-or-later",
13+
"license": "GPL-2.0-or-later",
1414
"authors": [
1515
{
1616
"name": "WebberZone",
17-
"email": "[email protected]",
1817
"role": "Developer"
1918
}
2019
],
2120
"requires": {
22-
"php": ">=7"
21+
"php": ">=7.4"
22+
},
23+
"require-dev": {
24+
"szepeviktor/phpstan-wordpress": "^1.3",
25+
"phpstan/extension-installer": "^1.3",
26+
"phpstan/phpstan": "^1.10",
27+
"php-stubs/wordpress-stubs": "^6.5",
28+
"wp-coding-standards/wpcs": "^3.0",
29+
"dealerdirect/phpcodesniffer-composer-installer": "^0.7",
30+
"phpcompatibility/phpcompatibility-wp": "^2.1",
31+
"yoast/phpunit-polyfills": "^1.0",
32+
"phpunit/phpunit": "^5.7.21 || ^6.5 || ^7.5"
33+
},
34+
"config": {
35+
"allow-plugins": {
36+
"phpstan/extension-installer": true,
37+
"dealerdirect/phpcodesniffer-composer-installer": true
38+
}
2339
}
2440
}

package.json

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
{
2+
"name": "@webberzone/knowledgebase",
3+
"version": "2.2.1",
4+
"description": "Fastest way to create a highly-flexible multi-product knowledge base.",
5+
"author": "WebberZone",
6+
"license": "GPL-2.0-or-later",
7+
"main": "index.js",
8+
"scripts": {
9+
"build": "wp-scripts build --webpack-src-dir=includes/blocks/src/ --output-path=includes/blocks/build/",
10+
"build:alerts": "wp-scripts build --webpack-src-dir=includes/pro/blocks/src/alerts/ --output-path=includes/pro/blocks/build/alerts/",
11+
"build:kb": "wp-scripts build --webpack-src-dir=includes/pro/blocks/src/kb/ --output-path=includes/pro/blocks/build/kb/",
12+
"format": "wp-scripts format ./includes/blocks/src/",
13+
"lint:css": "wp-scripts lint-style ./includes/blocks/src/",
14+
"lint:js": "wp-scripts lint-js ./includes/blocks/src/",
15+
"packages-update": "wp-scripts packages-update",
16+
"start": "wp-scripts start --webpack-src-dir=includes/blocks/src/ --output-path=includes/blocks/build/",
17+
"start:alerts": "wp-scripts start --webpack-src-dir=includes/pro/blocks/src/alerts/ --output-path=includes/pro/blocks/build/alerts/",
18+
"start:kb": "wp-scripts start --webpack-src-dir=includes/pro/blocks/src/kb/ --output-path=includes/pro/blocks/build/kb/",
19+
"zip": "wp-scripts plugin-zip"
20+
},
21+
"files": [
22+
"includes",
23+
"languages",
24+
"README.md",
25+
"knowledgebase.php",
26+
"index.php",
27+
"uninstall.php",
28+
"changelog.txt",
29+
"readme.txt"
30+
],
31+
"devDependencies": {
32+
"@wordpress/prettier-config": "^4.9.0",
33+
"@wordpress/scripts": "^27"
34+
},
35+
"dependencies": {
36+
"@wordpress/icons": "^10.9.0",
37+
"clsx": "^2.1.1",
38+
"uuid": "^10.0.0"
39+
}
40+
}

phpstan-baseline.neon

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
parameters:
2+
ignoreErrors:

phpstan.neon.dist

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
includes:
2+
- phpstan-baseline.neon
3+
parameters:
4+
level: 5
5+
scanFiles:
6+
- knowledgebase.php
7+
scanDirectories:
8+
- includes
9+
paths:
10+
- knowledgebase.php
11+
- uninstall.php
12+
- includes/
13+
ignoreErrors:

0 commit comments

Comments
 (0)