@loopress/cli 0.2.0 → 0.4.0
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/README.md +75 -283
- package/dist/commands/plugin/pull.d.ts +12 -0
- package/dist/commands/plugin/pull.js +48 -0
- package/dist/commands/plugin/push.d.ts +13 -0
- package/dist/commands/plugin/push.js +111 -0
- package/dist/commands/plugin/require.d.ts +17 -0
- package/dist/commands/plugin/require.js +74 -0
- package/dist/commands/{snippets → snippet}/pull.js +1 -0
- package/dist/commands/{snippets → snippet}/push.d.ts +2 -0
- package/dist/commands/{snippets → snippet}/push.js +35 -13
- package/dist/types/plugin.d.ts +15 -0
- package/dist/types/plugin.js +1 -0
- package/dist/utils/loopress-config.d.ts +2 -0
- package/dist/utils/loopress-config.js +8 -3
- package/dist/utils/plugins.d.ts +27 -0
- package/dist/utils/plugins.js +34 -0
- package/oclif.manifest.json +198 -16
- package/package.json +3 -4
- /package/dist/commands/{snippets → snippet}/list.d.ts +0 -0
- /package/dist/commands/{snippets → snippet}/list.js +0 -0
- /package/dist/commands/{snippets → snippet}/pull.d.ts +0 -0
- /package/dist/commands/{styles → style}/pull.d.ts +0 -0
- /package/dist/commands/{styles → style}/pull.js +0 -0
- /package/dist/commands/{styles → style}/push.d.ts +0 -0
- /package/dist/commands/{styles → style}/push.js +0 -0
package/oclif.manifest.json
CHANGED
|
@@ -46,6 +46,188 @@
|
|
|
46
46
|
"logout.js"
|
|
47
47
|
]
|
|
48
48
|
},
|
|
49
|
+
"plugin:pull": {
|
|
50
|
+
"aliases": [],
|
|
51
|
+
"args": {},
|
|
52
|
+
"description": "Pull installed plugins from WordPress into loopress.json",
|
|
53
|
+
"examples": [
|
|
54
|
+
"$ lps plugins pull",
|
|
55
|
+
"$ lps plugins pull --dry-run"
|
|
56
|
+
],
|
|
57
|
+
"flags": {
|
|
58
|
+
"password": {
|
|
59
|
+
"description": "WordPress application password (fallback; prefer `lps project config`)",
|
|
60
|
+
"helpGroup": "GLOBAL",
|
|
61
|
+
"name": "password",
|
|
62
|
+
"hasDynamicHelp": false,
|
|
63
|
+
"multiple": false,
|
|
64
|
+
"type": "option"
|
|
65
|
+
},
|
|
66
|
+
"url": {
|
|
67
|
+
"description": "WordPress URL (fallback; prefer `lps project config`)",
|
|
68
|
+
"helpGroup": "GLOBAL",
|
|
69
|
+
"name": "url",
|
|
70
|
+
"hasDynamicHelp": false,
|
|
71
|
+
"multiple": false,
|
|
72
|
+
"type": "option"
|
|
73
|
+
},
|
|
74
|
+
"user": {
|
|
75
|
+
"description": "WordPress username (fallback; prefer `lps project config`)",
|
|
76
|
+
"helpGroup": "GLOBAL",
|
|
77
|
+
"name": "user",
|
|
78
|
+
"hasDynamicHelp": false,
|
|
79
|
+
"multiple": false,
|
|
80
|
+
"type": "option"
|
|
81
|
+
},
|
|
82
|
+
"dry-run": {
|
|
83
|
+
"char": "d",
|
|
84
|
+
"description": "Show what would be written without making changes",
|
|
85
|
+
"name": "dry-run",
|
|
86
|
+
"allowNo": false,
|
|
87
|
+
"type": "boolean"
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
"hasDynamicHelp": false,
|
|
91
|
+
"hiddenAliases": [],
|
|
92
|
+
"id": "plugin:pull",
|
|
93
|
+
"pluginAlias": "@loopress/cli",
|
|
94
|
+
"pluginName": "@loopress/cli",
|
|
95
|
+
"pluginType": "core",
|
|
96
|
+
"strict": true,
|
|
97
|
+
"enableJsonFlag": false,
|
|
98
|
+
"isESM": true,
|
|
99
|
+
"relativePath": [
|
|
100
|
+
"dist",
|
|
101
|
+
"commands",
|
|
102
|
+
"plugin",
|
|
103
|
+
"pull.js"
|
|
104
|
+
]
|
|
105
|
+
},
|
|
106
|
+
"plugin:push": {
|
|
107
|
+
"aliases": [],
|
|
108
|
+
"args": {},
|
|
109
|
+
"description": "Sync plugins on WordPress to match loopress.json",
|
|
110
|
+
"examples": [
|
|
111
|
+
"$ lps plugins push",
|
|
112
|
+
"$ lps plugins push --dry-run"
|
|
113
|
+
],
|
|
114
|
+
"flags": {
|
|
115
|
+
"password": {
|
|
116
|
+
"description": "WordPress application password (fallback; prefer `lps project config`)",
|
|
117
|
+
"helpGroup": "GLOBAL",
|
|
118
|
+
"name": "password",
|
|
119
|
+
"hasDynamicHelp": false,
|
|
120
|
+
"multiple": false,
|
|
121
|
+
"type": "option"
|
|
122
|
+
},
|
|
123
|
+
"url": {
|
|
124
|
+
"description": "WordPress URL (fallback; prefer `lps project config`)",
|
|
125
|
+
"helpGroup": "GLOBAL",
|
|
126
|
+
"name": "url",
|
|
127
|
+
"hasDynamicHelp": false,
|
|
128
|
+
"multiple": false,
|
|
129
|
+
"type": "option"
|
|
130
|
+
},
|
|
131
|
+
"user": {
|
|
132
|
+
"description": "WordPress username (fallback; prefer `lps project config`)",
|
|
133
|
+
"helpGroup": "GLOBAL",
|
|
134
|
+
"name": "user",
|
|
135
|
+
"hasDynamicHelp": false,
|
|
136
|
+
"multiple": false,
|
|
137
|
+
"type": "option"
|
|
138
|
+
},
|
|
139
|
+
"dry-run": {
|
|
140
|
+
"char": "d",
|
|
141
|
+
"description": "Show what would change without making changes",
|
|
142
|
+
"name": "dry-run",
|
|
143
|
+
"allowNo": false,
|
|
144
|
+
"type": "boolean"
|
|
145
|
+
}
|
|
146
|
+
},
|
|
147
|
+
"hasDynamicHelp": false,
|
|
148
|
+
"hiddenAliases": [],
|
|
149
|
+
"id": "plugin:push",
|
|
150
|
+
"pluginAlias": "@loopress/cli",
|
|
151
|
+
"pluginName": "@loopress/cli",
|
|
152
|
+
"pluginType": "core",
|
|
153
|
+
"strict": true,
|
|
154
|
+
"enableJsonFlag": false,
|
|
155
|
+
"isESM": true,
|
|
156
|
+
"relativePath": [
|
|
157
|
+
"dist",
|
|
158
|
+
"commands",
|
|
159
|
+
"plugin",
|
|
160
|
+
"push.js"
|
|
161
|
+
]
|
|
162
|
+
},
|
|
163
|
+
"plugin:require": {
|
|
164
|
+
"aliases": [],
|
|
165
|
+
"args": {
|
|
166
|
+
"slug": {
|
|
167
|
+
"description": "Plugin slug (WordPress.org)",
|
|
168
|
+
"name": "slug",
|
|
169
|
+
"required": true
|
|
170
|
+
},
|
|
171
|
+
"version": {
|
|
172
|
+
"description": "Version to pin (default: latest)",
|
|
173
|
+
"name": "version"
|
|
174
|
+
}
|
|
175
|
+
},
|
|
176
|
+
"description": "Add a plugin to loopress.json, resolving its latest version from WordPress.org",
|
|
177
|
+
"examples": [
|
|
178
|
+
"$ lps plugins require woocommerce",
|
|
179
|
+
"$ lps plugins require woocommerce 8.9.1",
|
|
180
|
+
"$ lps plugins require contact-form-7 --dry-run"
|
|
181
|
+
],
|
|
182
|
+
"flags": {
|
|
183
|
+
"password": {
|
|
184
|
+
"description": "WordPress application password (fallback; prefer `lps project config`)",
|
|
185
|
+
"helpGroup": "GLOBAL",
|
|
186
|
+
"name": "password",
|
|
187
|
+
"hasDynamicHelp": false,
|
|
188
|
+
"multiple": false,
|
|
189
|
+
"type": "option"
|
|
190
|
+
},
|
|
191
|
+
"url": {
|
|
192
|
+
"description": "WordPress URL (fallback; prefer `lps project config`)",
|
|
193
|
+
"helpGroup": "GLOBAL",
|
|
194
|
+
"name": "url",
|
|
195
|
+
"hasDynamicHelp": false,
|
|
196
|
+
"multiple": false,
|
|
197
|
+
"type": "option"
|
|
198
|
+
},
|
|
199
|
+
"user": {
|
|
200
|
+
"description": "WordPress username (fallback; prefer `lps project config`)",
|
|
201
|
+
"helpGroup": "GLOBAL",
|
|
202
|
+
"name": "user",
|
|
203
|
+
"hasDynamicHelp": false,
|
|
204
|
+
"multiple": false,
|
|
205
|
+
"type": "option"
|
|
206
|
+
},
|
|
207
|
+
"dry-run": {
|
|
208
|
+
"char": "d",
|
|
209
|
+
"description": "Show what would be written without making changes",
|
|
210
|
+
"name": "dry-run",
|
|
211
|
+
"allowNo": false,
|
|
212
|
+
"type": "boolean"
|
|
213
|
+
}
|
|
214
|
+
},
|
|
215
|
+
"hasDynamicHelp": false,
|
|
216
|
+
"hiddenAliases": [],
|
|
217
|
+
"id": "plugin:require",
|
|
218
|
+
"pluginAlias": "@loopress/cli",
|
|
219
|
+
"pluginName": "@loopress/cli",
|
|
220
|
+
"pluginType": "core",
|
|
221
|
+
"strict": true,
|
|
222
|
+
"enableJsonFlag": false,
|
|
223
|
+
"isESM": true,
|
|
224
|
+
"relativePath": [
|
|
225
|
+
"dist",
|
|
226
|
+
"commands",
|
|
227
|
+
"plugin",
|
|
228
|
+
"require.js"
|
|
229
|
+
]
|
|
230
|
+
},
|
|
49
231
|
"project:config": {
|
|
50
232
|
"aliases": [],
|
|
51
233
|
"args": {},
|
|
@@ -190,7 +372,7 @@
|
|
|
190
372
|
"switch.js"
|
|
191
373
|
]
|
|
192
374
|
},
|
|
193
|
-
"
|
|
375
|
+
"snippet:list": {
|
|
194
376
|
"aliases": [],
|
|
195
377
|
"args": {},
|
|
196
378
|
"description": "List snippets from WordPress",
|
|
@@ -247,7 +429,7 @@
|
|
|
247
429
|
},
|
|
248
430
|
"hasDynamicHelp": false,
|
|
249
431
|
"hiddenAliases": [],
|
|
250
|
-
"id": "
|
|
432
|
+
"id": "snippet:list",
|
|
251
433
|
"pluginAlias": "@loopress/cli",
|
|
252
434
|
"pluginName": "@loopress/cli",
|
|
253
435
|
"pluginType": "core",
|
|
@@ -257,11 +439,11 @@
|
|
|
257
439
|
"relativePath": [
|
|
258
440
|
"dist",
|
|
259
441
|
"commands",
|
|
260
|
-
"
|
|
442
|
+
"snippet",
|
|
261
443
|
"list.js"
|
|
262
444
|
]
|
|
263
445
|
},
|
|
264
|
-
"
|
|
446
|
+
"snippet:pull": {
|
|
265
447
|
"aliases": [],
|
|
266
448
|
"args": {
|
|
267
449
|
"path": {
|
|
@@ -324,7 +506,7 @@
|
|
|
324
506
|
},
|
|
325
507
|
"hasDynamicHelp": false,
|
|
326
508
|
"hiddenAliases": [],
|
|
327
|
-
"id": "
|
|
509
|
+
"id": "snippet:pull",
|
|
328
510
|
"pluginAlias": "@loopress/cli",
|
|
329
511
|
"pluginName": "@loopress/cli",
|
|
330
512
|
"pluginType": "core",
|
|
@@ -334,11 +516,11 @@
|
|
|
334
516
|
"relativePath": [
|
|
335
517
|
"dist",
|
|
336
518
|
"commands",
|
|
337
|
-
"
|
|
519
|
+
"snippet",
|
|
338
520
|
"pull.js"
|
|
339
521
|
]
|
|
340
522
|
},
|
|
341
|
-
"
|
|
523
|
+
"snippet:push": {
|
|
342
524
|
"aliases": [],
|
|
343
525
|
"args": {
|
|
344
526
|
"path": {
|
|
@@ -401,7 +583,7 @@
|
|
|
401
583
|
},
|
|
402
584
|
"hasDynamicHelp": false,
|
|
403
585
|
"hiddenAliases": [],
|
|
404
|
-
"id": "
|
|
586
|
+
"id": "snippet:push",
|
|
405
587
|
"pluginAlias": "@loopress/cli",
|
|
406
588
|
"pluginName": "@loopress/cli",
|
|
407
589
|
"pluginType": "core",
|
|
@@ -411,11 +593,11 @@
|
|
|
411
593
|
"relativePath": [
|
|
412
594
|
"dist",
|
|
413
595
|
"commands",
|
|
414
|
-
"
|
|
596
|
+
"snippet",
|
|
415
597
|
"push.js"
|
|
416
598
|
]
|
|
417
599
|
},
|
|
418
|
-
"
|
|
600
|
+
"style:pull": {
|
|
419
601
|
"aliases": [],
|
|
420
602
|
"args": {},
|
|
421
603
|
"description": "Pull Global Styles from WordPress",
|
|
@@ -458,7 +640,7 @@
|
|
|
458
640
|
},
|
|
459
641
|
"hasDynamicHelp": false,
|
|
460
642
|
"hiddenAliases": [],
|
|
461
|
-
"id": "
|
|
643
|
+
"id": "style:pull",
|
|
462
644
|
"pluginAlias": "@loopress/cli",
|
|
463
645
|
"pluginName": "@loopress/cli",
|
|
464
646
|
"pluginType": "core",
|
|
@@ -468,11 +650,11 @@
|
|
|
468
650
|
"relativePath": [
|
|
469
651
|
"dist",
|
|
470
652
|
"commands",
|
|
471
|
-
"
|
|
653
|
+
"style",
|
|
472
654
|
"pull.js"
|
|
473
655
|
]
|
|
474
656
|
},
|
|
475
|
-
"
|
|
657
|
+
"style:push": {
|
|
476
658
|
"aliases": [],
|
|
477
659
|
"args": {},
|
|
478
660
|
"description": "Push Global Styles to WordPress",
|
|
@@ -515,7 +697,7 @@
|
|
|
515
697
|
},
|
|
516
698
|
"hasDynamicHelp": false,
|
|
517
699
|
"hiddenAliases": [],
|
|
518
|
-
"id": "
|
|
700
|
+
"id": "style:push",
|
|
519
701
|
"pluginAlias": "@loopress/cli",
|
|
520
702
|
"pluginName": "@loopress/cli",
|
|
521
703
|
"pluginType": "core",
|
|
@@ -525,10 +707,10 @@
|
|
|
525
707
|
"relativePath": [
|
|
526
708
|
"dist",
|
|
527
709
|
"commands",
|
|
528
|
-
"
|
|
710
|
+
"style",
|
|
529
711
|
"push.js"
|
|
530
712
|
]
|
|
531
713
|
}
|
|
532
714
|
},
|
|
533
|
-
"version": "0.
|
|
715
|
+
"version": "0.4.0"
|
|
534
716
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@loopress/cli",
|
|
3
3
|
"description": "CLI tool for syncing WordPress CodeSnippets, styles, and menus via the REST API",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.4.0",
|
|
5
5
|
"author": "jean-smaug",
|
|
6
6
|
"bin": {
|
|
7
7
|
"loopress": "bin/run.js",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"@oclif/prettier-config": "^0.2.1",
|
|
25
25
|
"@oclif/test": "^4",
|
|
26
26
|
"@types/chai": "^5.2.3",
|
|
27
|
-
"@types/mocha": "^10",
|
|
27
|
+
"@types/mocha": "^10.0.10",
|
|
28
28
|
"@types/node": "25.9.3",
|
|
29
29
|
"chai": "^6.2.2",
|
|
30
30
|
"eslint": "^9",
|
|
@@ -63,8 +63,7 @@
|
|
|
63
63
|
"commands": "./dist/commands",
|
|
64
64
|
"helpClass": "./dist/help.js",
|
|
65
65
|
"plugins": [
|
|
66
|
-
"@oclif/plugin-help"
|
|
67
|
-
"@oclif/plugin-plugins"
|
|
66
|
+
"@oclif/plugin-help"
|
|
68
67
|
],
|
|
69
68
|
"topicSeparator": " "
|
|
70
69
|
},
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|