@airfleet/generator-init 0.16.0 → 0.17.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.
- package/generators/plugin/templates/.github/workflows/release-plugin.yml +27 -7
- package/generators/plugin/templates/.vscode/settings.json +25 -2
- package/generators/plugin/templates/composer.json.ejs +4 -3
- package/generators/plugin/templates/package.json.ejs +18 -17
- package/generators/plugin/templates/phpcs.xml.ejs +0 -4
- package/generators/plugin/templates/plugin-name.php.ejs +0 -1
- package/package.json +1 -1
|
@@ -166,18 +166,38 @@ jobs:
|
|
|
166
166
|
# Reference https://trentm.com/json/
|
|
167
167
|
run: |
|
|
168
168
|
NL=$'\n'
|
|
169
|
+
echo "Plugins current:"
|
|
170
|
+
cat $RUNNER_TEMP/plugins.json | json
|
|
171
|
+
echo "$NL $NL $NL"
|
|
169
172
|
PLUGIN_SLUG=$(cat $RUNNER_TEMP/plugin.json | json slug)
|
|
170
173
|
echo "Plugin slug: $PLUGIN_SLUG"
|
|
171
|
-
|
|
174
|
+
echo "$NL $NL $NL"
|
|
172
175
|
echo "Plugin versions:"
|
|
173
|
-
|
|
174
|
-
|
|
176
|
+
cat $RUNNER_TEMP/plugin.json | json versions > $RUNNER_TEMP/plugin_new_version.json
|
|
177
|
+
cat $RUNNER_TEMP/plugins.json | json plugins | json -c "this.slug === '$PLUGIN_SLUG'" | json 0.versions > $RUNNER_TEMP/plugin_existing_versions.json
|
|
178
|
+
cat $RUNNER_TEMP/plugin_new_version.json $RUNNER_TEMP/plugin_existing_versions.json | json --group > $RUNNER_TEMP/plugin_versions.json
|
|
179
|
+
printf '%s\n%s\n%s\n' '{"versions":' "$(cat $RUNNER_TEMP/plugin_versions.json)" '}' | json > $RUNNER_TEMP/plugin_versions_final.json
|
|
180
|
+
cat $RUNNER_TEMP/plugin_versions_final.json
|
|
181
|
+
echo "$NL $NL $NL"
|
|
175
182
|
echo "Plugin updated:"
|
|
176
|
-
|
|
177
|
-
|
|
183
|
+
cat $RUNNER_TEMP/plugins.json | json plugins | json -c "this.slug === '$PLUGIN_SLUG'" | json 0 > $RUNNER_TEMP/plugin_existing.json
|
|
184
|
+
cat $RUNNER_TEMP/plugin.json | json > $RUNNER_TEMP/plugin_formatted.json
|
|
185
|
+
cat $RUNNER_TEMP/plugin_existing.json $RUNNER_TEMP/plugin_formatted.json $RUNNER_TEMP/plugin_versions_final.json | json --merge | json > $RUNNER_TEMP/plugin_updated.json
|
|
186
|
+
cat $RUNNER_TEMP/plugin_updated.json
|
|
187
|
+
echo "$NL $NL $NL"
|
|
178
188
|
echo "Plugins list updated:"
|
|
179
|
-
|
|
180
|
-
cat $RUNNER_TEMP/
|
|
189
|
+
cat $RUNNER_TEMP/plugins.json | json plugins | json -c "this.slug !== '$PLUGIN_SLUG'" > $RUNNER_TEMP/plugins_list_excluded.json
|
|
190
|
+
cat $RUNNER_TEMP/plugin_updated.json | json --group > $RUNNER_TEMP/plugins_list_added.json
|
|
191
|
+
cat $RUNNER_TEMP/plugins_list_excluded.json $RUNNER_TEMP/plugins_list_added.json | json --group > $RUNNER_TEMP/plugins_list_updated.json
|
|
192
|
+
cat $RUNNER_TEMP/plugins_list_updated.json
|
|
193
|
+
echo "$NL $NL $NL"
|
|
194
|
+
echo "Plugins updated:"
|
|
195
|
+
printf '%s\n%s\n%s\n' '{"plugins":' "$(cat $RUNNER_TEMP/plugins_list_updated.json)" '}' | json > $RUNNER_TEMP/plugins_new.json
|
|
196
|
+
cat $RUNNER_TEMP/plugins_new.json
|
|
197
|
+
echo "$NL $NL $NL"
|
|
198
|
+
echo "Final merge:"
|
|
199
|
+
cat $RUNNER_TEMP/plugins.json $RUNNER_TEMP/plugins_new.json | json --merge > $RUNNER_TEMP/plugins_updated.json
|
|
200
|
+
cat $RUNNER_TEMP/plugins_updated.json
|
|
181
201
|
|
|
182
202
|
- name: 🚀 Upload updated plugins list to AWS
|
|
183
203
|
run: |
|
|
@@ -1,10 +1,33 @@
|
|
|
1
1
|
{
|
|
2
2
|
"editor.codeActionsOnSave": {
|
|
3
|
-
"source.fixAll": true
|
|
3
|
+
"source.fixAll": true,
|
|
4
|
+
"source.fixAll.eslint": true
|
|
4
5
|
},
|
|
5
6
|
"editor.formatOnSave": true,
|
|
6
7
|
"stylelint.validate": ["css", "scss", "postcss"],
|
|
8
|
+
"phpSniffer.autoDetect": true,
|
|
7
9
|
"[php]": {
|
|
8
|
-
"editor.
|
|
10
|
+
"editor.defaultFormatter": "wongjn.php-sniffer"
|
|
11
|
+
},
|
|
12
|
+
"[javascript]": {
|
|
13
|
+
"editor.defaultFormatter": "dbaeumer.vscode-eslint"
|
|
14
|
+
},
|
|
15
|
+
"[javascriptreact]": {
|
|
16
|
+
"editor.defaultFormatter": "dbaeumer.vscode-eslint"
|
|
17
|
+
},
|
|
18
|
+
"[typescript]": {
|
|
19
|
+
"editor.defaultFormatter": "dbaeumer.vscode-eslint"
|
|
20
|
+
},
|
|
21
|
+
"[typescriptreact]": {
|
|
22
|
+
"editor.defaultFormatter": "dbaeumer.vscode-eslint"
|
|
23
|
+
},
|
|
24
|
+
"[postcss]": {
|
|
25
|
+
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
|
26
|
+
},
|
|
27
|
+
"[scss]": {
|
|
28
|
+
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
|
29
|
+
},
|
|
30
|
+
"[css]": {
|
|
31
|
+
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
|
9
32
|
}
|
|
10
33
|
}
|
|
@@ -12,8 +12,8 @@
|
|
|
12
12
|
"composer/installers": "^2.0"
|
|
13
13
|
},
|
|
14
14
|
"require-dev": {
|
|
15
|
-
"airfleet/wordpress-dev": "^
|
|
16
|
-
"wpify/scoper": "
|
|
15
|
+
"airfleet/wordpress-dev": "^3.0.1",
|
|
16
|
+
"wpify/scoper": "2.5.4"
|
|
17
17
|
},
|
|
18
18
|
"autoload": {
|
|
19
19
|
"psr-4": {
|
|
@@ -47,5 +47,6 @@
|
|
|
47
47
|
"composerjson": "composer-scoped.json",
|
|
48
48
|
"composerlock": "composer-scoped.lock"
|
|
49
49
|
}
|
|
50
|
-
}
|
|
50
|
+
},
|
|
51
|
+
"minimum-stability": "dev"
|
|
51
52
|
}
|
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
"description": "<%= answers.pluginDescription %>",
|
|
4
4
|
"version": "<%= answers.pluginVersion %>",
|
|
5
5
|
"scripts": {
|
|
6
|
-
"build": "dotenv -- parcel build --log-level verbose \"./!(dist)/**/*.entry.{js,scss}\"",
|
|
7
|
-
"start": "dotenv -- parcel serve --hmr-port 1236 --port 1234 --log-level verbose \"./!(dist)/**/*.entry.{js,scss}\"",
|
|
8
|
-
"watch": "dotenv -- parcel watch --no-hmr --log-level verbose \"./!(dist)/**/*.entry.{js,scss}\"",
|
|
6
|
+
"build": "dotenv -- parcel build --no-source-maps --log-level verbose \"./!(dist)/**/*.entry.{js,css,scss}\"",
|
|
7
|
+
"start": "dotenv -- parcel serve --hmr-port 1236 --port 1234 --log-level verbose \"./!(dist)/**/*.entry.{js,css,scss}\"",
|
|
8
|
+
"watch": "dotenv -- parcel watch --no-hmr --log-level verbose \"./!(dist)/**/*.entry.{js,css,scss}\"",
|
|
9
9
|
"base:eslint": "eslint \"**/*.js\" --cache --ignore-path .gitignore",
|
|
10
|
-
"base:prettier": "prettier \"**/*.{
|
|
10
|
+
"base:prettier": "prettier \"**/*.{css,scss}\"",
|
|
11
11
|
"base:stylelint": "stylelint \"**/*.{css,scss}\" --cache --ignore-path .gitignore --allow-empty-input",
|
|
12
12
|
"lint": "run-s --continue-on-error lint:*",
|
|
13
13
|
"lint:prettier": "npm run base:prettier -- --check",
|
|
@@ -21,8 +21,7 @@
|
|
|
21
21
|
"fix:phpcs": "composer run fix",
|
|
22
22
|
"pretest": "npm run lint",
|
|
23
23
|
"test": "echo Testing done",
|
|
24
|
-
"prepare": "husky install"
|
|
25
|
-
"cz": "git-cz"
|
|
24
|
+
"prepare": "husky install"
|
|
26
25
|
},
|
|
27
26
|
"private": true,
|
|
28
27
|
"keywords": [
|
|
@@ -43,12 +42,17 @@
|
|
|
43
42
|
},
|
|
44
43
|
"dependencies": {},
|
|
45
44
|
"devDependencies": {
|
|
46
|
-
"@airfleet/wordpress-dev": "^
|
|
45
|
+
"@airfleet/wordpress-dev": "^2.1.2"
|
|
47
46
|
},
|
|
48
47
|
"browserslist": [
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
48
|
+
"defaults",
|
|
49
|
+
"not dead",
|
|
50
|
+
"not op_mini all",
|
|
51
|
+
"not op_mob > 0",
|
|
52
|
+
"not opera > 0",
|
|
53
|
+
"not kaios > 0",
|
|
54
|
+
"not and_qq > 0",
|
|
55
|
+
"not and_uc > 0"
|
|
52
56
|
],
|
|
53
57
|
"prettier": "@airfleet/prettier-config-wordpress",
|
|
54
58
|
"stylelint": {
|
|
@@ -63,17 +67,14 @@
|
|
|
63
67
|
]
|
|
64
68
|
},
|
|
65
69
|
"lint-staged": {
|
|
66
|
-
"*.{js,jsx,ts,tsx,json,css,scss,xml,yaml,yml,md}": "prettier --write",
|
|
67
70
|
"*.{js,jsx}": "eslint --cache --ignore-path .gitignore --fix",
|
|
68
|
-
"*.{css,scss}":
|
|
71
|
+
"*.{css,scss}": [
|
|
72
|
+
"prettier --write",
|
|
73
|
+
"stylelint --cache --ignore-path .gitignore --fix"
|
|
74
|
+
],
|
|
69
75
|
"*.php": [
|
|
70
76
|
"composer run fix",
|
|
71
77
|
"composer run lint"
|
|
72
78
|
]
|
|
73
|
-
},
|
|
74
|
-
"config": {
|
|
75
|
-
"commitizen": {
|
|
76
|
-
"path": "./node_modules/cz-conventional-changelog"
|
|
77
|
-
}
|
|
78
79
|
}
|
|
79
80
|
}
|
|
@@ -14,10 +14,6 @@
|
|
|
14
14
|
<!-- Set cache file -->
|
|
15
15
|
<arg name="cache" value=".phpcscache" />
|
|
16
16
|
|
|
17
|
-
<!-- Ignore the vendor-scoped folder -->
|
|
18
|
-
<exclude-pattern>vendor-scoped/*</exclude-pattern>
|
|
19
|
-
<exclude-pattern><%= name.slug %>/wp-content/*</exclude-pattern>
|
|
20
|
-
|
|
21
17
|
<!-- Check all files in this directory and the directories below it. -->
|
|
22
18
|
<file>.</file>
|
|
23
19
|
|