@adobe/aio-cli-plugin-app 14.4.0 → 14.4.2
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 +32 -31
- package/oclif.manifest.json +2 -2
- package/package.json +1 -1
- package/src/commands/app/install.js +11 -1
- package/src/commands/app/pack.js +26 -1
package/README.md
CHANGED
|
@@ -75,7 +75,7 @@ DESCRIPTION
|
|
|
75
75
|
Create, run, test, and deploy Adobe I/O Apps
|
|
76
76
|
```
|
|
77
77
|
|
|
78
|
-
_See code: [src/commands/app/index.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
78
|
+
_See code: [src/commands/app/index.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/index.js)_
|
|
79
79
|
|
|
80
80
|
## `aio app add`
|
|
81
81
|
|
|
@@ -94,7 +94,7 @@ DESCRIPTION
|
|
|
94
94
|
Add a new component to an existing Adobe I/O App
|
|
95
95
|
```
|
|
96
96
|
|
|
97
|
-
_See code: [src/commands/app/add/index.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
97
|
+
_See code: [src/commands/app/add/index.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/add/index.js)_
|
|
98
98
|
|
|
99
99
|
## `aio app add action`
|
|
100
100
|
|
|
@@ -120,7 +120,7 @@ ALIASES
|
|
|
120
120
|
$ aio app add actions
|
|
121
121
|
```
|
|
122
122
|
|
|
123
|
-
_See code: [src/commands/app/add/action.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
123
|
+
_See code: [src/commands/app/add/action.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/add/action.js)_
|
|
124
124
|
|
|
125
125
|
## `aio app add ci`
|
|
126
126
|
|
|
@@ -139,7 +139,7 @@ DESCRIPTION
|
|
|
139
139
|
Add CI files
|
|
140
140
|
```
|
|
141
141
|
|
|
142
|
-
_See code: [src/commands/app/add/ci.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
142
|
+
_See code: [src/commands/app/add/ci.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/add/ci.js)_
|
|
143
143
|
|
|
144
144
|
## `aio app add event`
|
|
145
145
|
|
|
@@ -165,7 +165,7 @@ ALIASES
|
|
|
165
165
|
$ aio app add events
|
|
166
166
|
```
|
|
167
167
|
|
|
168
|
-
_See code: [src/commands/app/add/event.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
168
|
+
_See code: [src/commands/app/add/event.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/add/event.js)_
|
|
169
169
|
|
|
170
170
|
## `aio app add extension`
|
|
171
171
|
|
|
@@ -192,7 +192,7 @@ ALIASES
|
|
|
192
192
|
$ aio app add extensions
|
|
193
193
|
```
|
|
194
194
|
|
|
195
|
-
_See code: [src/commands/app/add/extension.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
195
|
+
_See code: [src/commands/app/add/extension.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/add/extension.js)_
|
|
196
196
|
|
|
197
197
|
## `aio app add service`
|
|
198
198
|
|
|
@@ -217,7 +217,7 @@ ALIASES
|
|
|
217
217
|
$ aio app add services
|
|
218
218
|
```
|
|
219
219
|
|
|
220
|
-
_See code: [src/commands/app/add/service.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
220
|
+
_See code: [src/commands/app/add/service.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/add/service.js)_
|
|
221
221
|
|
|
222
222
|
## `aio app add web-assets`
|
|
223
223
|
|
|
@@ -239,7 +239,7 @@ DESCRIPTION
|
|
|
239
239
|
Add web assets support
|
|
240
240
|
```
|
|
241
241
|
|
|
242
|
-
_See code: [src/commands/app/add/web-assets.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
242
|
+
_See code: [src/commands/app/add/web-assets.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/add/web-assets.js)_
|
|
243
243
|
|
|
244
244
|
## `aio app build`
|
|
245
245
|
|
|
@@ -270,7 +270,7 @@ DESCRIPTION
|
|
|
270
270
|
Use the --force-build flag to force a build even if one already exists.
|
|
271
271
|
```
|
|
272
272
|
|
|
273
|
-
_See code: [src/commands/app/build.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
273
|
+
_See code: [src/commands/app/build.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/build.js)_
|
|
274
274
|
|
|
275
275
|
## `aio app clean`
|
|
276
276
|
|
|
@@ -296,7 +296,7 @@ DESCRIPTION
|
|
|
296
296
|
Note that this will require a full rebuild on your next build command.
|
|
297
297
|
```
|
|
298
298
|
|
|
299
|
-
_See code: [src/commands/app/clean.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
299
|
+
_See code: [src/commands/app/clean.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/clean.js)_
|
|
300
300
|
|
|
301
301
|
## `aio app create [PATH]`
|
|
302
302
|
|
|
@@ -319,7 +319,7 @@ DESCRIPTION
|
|
|
319
319
|
Create a new Adobe I/O App with default parameters
|
|
320
320
|
```
|
|
321
321
|
|
|
322
|
-
_See code: [src/commands/app/create.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
322
|
+
_See code: [src/commands/app/create.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/create.js)_
|
|
323
323
|
|
|
324
324
|
## `aio app delete`
|
|
325
325
|
|
|
@@ -338,7 +338,7 @@ DESCRIPTION
|
|
|
338
338
|
Delete a component from an existing Adobe I/O App
|
|
339
339
|
```
|
|
340
340
|
|
|
341
|
-
_See code: [src/commands/app/delete/index.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
341
|
+
_See code: [src/commands/app/delete/index.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/delete/index.js)_
|
|
342
342
|
|
|
343
343
|
## `aio app delete action [ACTION-NAME]`
|
|
344
344
|
|
|
@@ -365,7 +365,7 @@ ALIASES
|
|
|
365
365
|
$ aio app delete actions
|
|
366
366
|
```
|
|
367
367
|
|
|
368
|
-
_See code: [src/commands/app/delete/action.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
368
|
+
_See code: [src/commands/app/delete/action.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/delete/action.js)_
|
|
369
369
|
|
|
370
370
|
## `aio app delete ci`
|
|
371
371
|
|
|
@@ -385,7 +385,7 @@ DESCRIPTION
|
|
|
385
385
|
Delete existing CI files
|
|
386
386
|
```
|
|
387
387
|
|
|
388
|
-
_See code: [src/commands/app/delete/ci.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
388
|
+
_See code: [src/commands/app/delete/ci.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/delete/ci.js)_
|
|
389
389
|
|
|
390
390
|
## `aio app delete extension`
|
|
391
391
|
|
|
@@ -412,7 +412,7 @@ ALIASES
|
|
|
412
412
|
$ aio app delete extensions
|
|
413
413
|
```
|
|
414
414
|
|
|
415
|
-
_See code: [src/commands/app/delete/extension.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
415
|
+
_See code: [src/commands/app/delete/extension.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/delete/extension.js)_
|
|
416
416
|
|
|
417
417
|
## `aio app delete service`
|
|
418
418
|
|
|
@@ -437,7 +437,7 @@ ALIASES
|
|
|
437
437
|
$ aio app delete services
|
|
438
438
|
```
|
|
439
439
|
|
|
440
|
-
_See code: [src/commands/app/delete/service.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
440
|
+
_See code: [src/commands/app/delete/service.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/delete/service.js)_
|
|
441
441
|
|
|
442
442
|
## `aio app delete web-assets`
|
|
443
443
|
|
|
@@ -457,7 +457,7 @@ DESCRIPTION
|
|
|
457
457
|
Delete existing web assets
|
|
458
458
|
```
|
|
459
459
|
|
|
460
|
-
_See code: [src/commands/app/delete/web-assets.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
460
|
+
_See code: [src/commands/app/delete/web-assets.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/delete/web-assets.js)_
|
|
461
461
|
|
|
462
462
|
## `aio app deploy`
|
|
463
463
|
|
|
@@ -504,7 +504,7 @@ DESCRIPTION
|
|
|
504
504
|
Use the --force-deploy flag to force deploy changes, regardless of production Workspace being published in Exchange.
|
|
505
505
|
```
|
|
506
506
|
|
|
507
|
-
_See code: [src/commands/app/deploy.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
507
|
+
_See code: [src/commands/app/deploy.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/deploy.js)_
|
|
508
508
|
|
|
509
509
|
## `aio app get-url [ACTION]`
|
|
510
510
|
|
|
@@ -527,7 +527,7 @@ DESCRIPTION
|
|
|
527
527
|
Get action URLs
|
|
528
528
|
```
|
|
529
529
|
|
|
530
|
-
_See code: [src/commands/app/get-url.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
530
|
+
_See code: [src/commands/app/get-url.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/get-url.js)_
|
|
531
531
|
|
|
532
532
|
## `aio app info`
|
|
533
533
|
|
|
@@ -550,7 +550,7 @@ DESCRIPTION
|
|
|
550
550
|
Display settings/configuration in use by an Adobe I/O App
|
|
551
551
|
```
|
|
552
552
|
|
|
553
|
-
_See code: [src/commands/app/info.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
553
|
+
_See code: [src/commands/app/info.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/info.js)_
|
|
554
554
|
|
|
555
555
|
## `aio app init [PATH]`
|
|
556
556
|
|
|
@@ -594,7 +594,7 @@ DESCRIPTION
|
|
|
594
594
|
Create a new Adobe I/O App
|
|
595
595
|
```
|
|
596
596
|
|
|
597
|
-
_See code: [src/commands/app/init.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
597
|
+
_See code: [src/commands/app/init.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/init.js)_
|
|
598
598
|
|
|
599
599
|
## `aio app install PATH`
|
|
600
600
|
|
|
@@ -619,7 +619,7 @@ DESCRIPTION
|
|
|
619
619
|
This command will support installing apps packaged by 'aio app pack'.
|
|
620
620
|
```
|
|
621
621
|
|
|
622
|
-
_See code: [src/commands/app/install.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
622
|
+
_See code: [src/commands/app/install.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/install.js)_
|
|
623
623
|
|
|
624
624
|
## `aio app list`
|
|
625
625
|
|
|
@@ -638,7 +638,7 @@ DESCRIPTION
|
|
|
638
638
|
List components for Adobe I/O App
|
|
639
639
|
```
|
|
640
640
|
|
|
641
|
-
_See code: [src/commands/app/list/index.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
641
|
+
_See code: [src/commands/app/list/index.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/list/index.js)_
|
|
642
642
|
|
|
643
643
|
## `aio app list extension`
|
|
644
644
|
|
|
@@ -664,7 +664,7 @@ ALIASES
|
|
|
664
664
|
$ aio app list extensions
|
|
665
665
|
```
|
|
666
666
|
|
|
667
|
-
_See code: [src/commands/app/list/extension.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
667
|
+
_See code: [src/commands/app/list/extension.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/list/extension.js)_
|
|
668
668
|
|
|
669
669
|
## `aio app logs`
|
|
670
670
|
|
|
@@ -689,7 +689,7 @@ DESCRIPTION
|
|
|
689
689
|
Fetch logs for an Adobe I/O App
|
|
690
690
|
```
|
|
691
691
|
|
|
692
|
-
_See code: [src/commands/app/logs.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
692
|
+
_See code: [src/commands/app/logs.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/logs.js)_
|
|
693
693
|
|
|
694
694
|
## `aio app pack [PATH]`
|
|
695
695
|
|
|
@@ -706,14 +706,15 @@ FLAGS
|
|
|
706
706
|
-o, --output=<value> [default: dist/app.zip] The packaged app output file path
|
|
707
707
|
-v, --verbose Verbose output
|
|
708
708
|
--[no-]config-validation [default: true] Validate the app configuration file(s) before continuing.
|
|
709
|
-
--[no-]lock-file Include the package-lock.json file in the packaged app
|
|
709
|
+
--[no-]lock-file Include the package-lock.json file in the packaged app. When disabled, compatibility
|
|
710
|
+
validation is skipped since the provisioner will use npm install instead of npm ci.
|
|
710
711
|
--version Show version
|
|
711
712
|
|
|
712
713
|
DESCRIPTION
|
|
713
714
|
This command will support packaging apps for redistribution.
|
|
714
715
|
```
|
|
715
716
|
|
|
716
|
-
_See code: [src/commands/app/pack.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
717
|
+
_See code: [src/commands/app/pack.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/pack.js)_
|
|
717
718
|
|
|
718
719
|
## `aio app run`
|
|
719
720
|
|
|
@@ -737,7 +738,7 @@ DESCRIPTION
|
|
|
737
738
|
Run an Adobe I/O App
|
|
738
739
|
```
|
|
739
740
|
|
|
740
|
-
_See code: [src/commands/app/run.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
741
|
+
_See code: [src/commands/app/run.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/run.js)_
|
|
741
742
|
|
|
742
743
|
## `aio app test`
|
|
743
744
|
|
|
@@ -767,7 +768,7 @@ DESCRIPTION
|
|
|
767
768
|
If the extension has a hook called 'test' in its 'ext.config.yaml', the script specified will be run instead.
|
|
768
769
|
```
|
|
769
770
|
|
|
770
|
-
_See code: [src/commands/app/test.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
771
|
+
_See code: [src/commands/app/test.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/test.js)_
|
|
771
772
|
|
|
772
773
|
## `aio app undeploy`
|
|
773
774
|
|
|
@@ -793,7 +794,7 @@ DESCRIPTION
|
|
|
793
794
|
Undeploys an Adobe I/O App
|
|
794
795
|
```
|
|
795
796
|
|
|
796
|
-
_See code: [src/commands/app/undeploy.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
797
|
+
_See code: [src/commands/app/undeploy.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/undeploy.js)_
|
|
797
798
|
|
|
798
799
|
## `aio app use [CONFIG_FILE_PATH]`
|
|
799
800
|
|
|
@@ -841,5 +842,5 @@ DESCRIPTION
|
|
|
841
842
|
page in https://developer.adobe.com/console/
|
|
842
843
|
```
|
|
843
844
|
|
|
844
|
-
_See code: [src/commands/app/use.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.
|
|
845
|
+
_See code: [src/commands/app/use.js](https://github.com/adobe/aio-cli-plugin-app/blob/14.4.2/src/commands/app/use.js)_
|
|
845
846
|
<!-- commandsstop -->
|
package/oclif.manifest.json
CHANGED
|
@@ -923,7 +923,7 @@
|
|
|
923
923
|
"type": "boolean"
|
|
924
924
|
},
|
|
925
925
|
"lock-file": {
|
|
926
|
-
"description": "Include the package-lock.json file in the packaged app",
|
|
926
|
+
"description": "Include the package-lock.json file in the packaged app. When disabled, compatibility validation is skipped since the provisioner will use npm install instead of npm ci.",
|
|
927
927
|
"name": "lock-file",
|
|
928
928
|
"allowNo": true,
|
|
929
929
|
"type": "boolean"
|
|
@@ -2434,5 +2434,5 @@
|
|
|
2434
2434
|
]
|
|
2435
2435
|
}
|
|
2436
2436
|
},
|
|
2437
|
-
"version": "14.4.
|
|
2437
|
+
"version": "14.4.2"
|
|
2438
2438
|
}
|
package/package.json
CHANGED
|
@@ -54,7 +54,17 @@ class InstallCommand extends BaseCommand {
|
|
|
54
54
|
|
|
55
55
|
const packageLockPath = path.join(outputPath, PACKAGE_LOCK_FILE)
|
|
56
56
|
if (fs.existsSync(packageLockPath)) {
|
|
57
|
-
|
|
57
|
+
try {
|
|
58
|
+
await this.npmCI(flags.verbose, flags['allow-scripts'])
|
|
59
|
+
} catch (npmCIError) {
|
|
60
|
+
// Log the npm ci failure for monitoring
|
|
61
|
+
aioLogger.warn(`npm ci failed: ${npmCIError.message}`)
|
|
62
|
+
aioLogger.debug('npm ci error details:', npmCIError)
|
|
63
|
+
|
|
64
|
+
// Fallback to npm install with a warning message
|
|
65
|
+
this.warn('npm ci failed (lockfile out of sync). Falling back to npm install.')
|
|
66
|
+
await this.npmInstall(flags.verbose, flags['allow-scripts'])
|
|
67
|
+
}
|
|
58
68
|
} else {
|
|
59
69
|
this.warn('No lockfile found, running standard npm install. It is recommended that you include a lockfile with your app bundle.')
|
|
60
70
|
await this.npmInstall(flags.verbose, flags['allow-scripts'])
|
package/src/commands/app/pack.js
CHANGED
|
@@ -57,6 +57,11 @@ class Pack extends BaseCommand {
|
|
|
57
57
|
.map(([, extConfig]) => path.relative(process.cwd(), extConfig.app.dist))
|
|
58
58
|
|
|
59
59
|
try {
|
|
60
|
+
// 0. validate package.json and package-lock.json compatibility (skip if --no-lock-file)
|
|
61
|
+
if (flags['lock-file']) {
|
|
62
|
+
await this.validatePackageLockCompatibility()
|
|
63
|
+
}
|
|
64
|
+
|
|
60
65
|
// 1. create artifacts phase
|
|
61
66
|
this.spinner.start(`Creating package artifacts folder '${DEFAULTS.ARTIFACTS_FOLDER_PATH}'...`)
|
|
62
67
|
await fs.emptyDir(DEFAULTS.ARTIFACTS_FOLDER_PATH)
|
|
@@ -127,6 +132,26 @@ class Pack extends BaseCommand {
|
|
|
127
132
|
return this._spinner
|
|
128
133
|
}
|
|
129
134
|
|
|
135
|
+
/**
|
|
136
|
+
* Validates that package.json and package-lock.json are compatible
|
|
137
|
+
*/
|
|
138
|
+
async validatePackageLockCompatibility () {
|
|
139
|
+
const packageLockPath = path.join(process.cwd(), 'package-lock.json')
|
|
140
|
+
if (!(await fs.pathExists(packageLockPath))) {
|
|
141
|
+
return
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
this.spinner.start('Validating package.json and package-lock.json compatibility...')
|
|
145
|
+
try {
|
|
146
|
+
await execa('npm', ['ci', '--dry-run'], { cwd: process.cwd() })
|
|
147
|
+
this.spinner.succeed('Validated package.json and package-lock.json compatibility')
|
|
148
|
+
} catch (error) {
|
|
149
|
+
this.spinner.fail('package.json and package-lock.json are incompatible')
|
|
150
|
+
const errorMessage = error.stderr || error.message || 'npm ci --dry-run failed'
|
|
151
|
+
throw new Error(`package.json and package-lock.json are incompatible. Run 'npm install' to update your package-lock.json.\n\nError: ${errorMessage}`)
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
|
|
130
155
|
/**
|
|
131
156
|
* Creates the deploy.yaml file
|
|
132
157
|
*
|
|
@@ -371,7 +396,7 @@ Pack.description = `This command will support packaging apps for redistribution.
|
|
|
371
396
|
Pack.flags = {
|
|
372
397
|
...BaseCommand.flags,
|
|
373
398
|
'lock-file': Flags.boolean({
|
|
374
|
-
description: 'Include the package-lock.json file in the packaged app',
|
|
399
|
+
description: 'Include the package-lock.json file in the packaged app. When disabled, compatibility validation is skipped since the provisioner will use npm install instead of npm ci.',
|
|
375
400
|
default: true,
|
|
376
401
|
allowNo: true
|
|
377
402
|
}),
|