@form8ion/javascript 11.7.0 → 11.7.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/lib/index.js +16 -6
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +16 -6
- package/lib/index.mjs.map +1 -1
- package/package.json +2 -2
package/lib/index.mjs
CHANGED
|
@@ -107,7 +107,7 @@ async function lift$2({projectRoot, packageManager}) {
|
|
|
107
107
|
]);
|
|
108
108
|
}
|
|
109
109
|
|
|
110
|
-
return
|
|
110
|
+
return codecovResults;
|
|
111
111
|
}
|
|
112
112
|
|
|
113
113
|
function c8IsConfigured ({projectRoot}) {
|
|
@@ -467,8 +467,8 @@ async function scaffoldPackageType ({
|
|
|
467
467
|
]);
|
|
468
468
|
}
|
|
469
469
|
|
|
470
|
-
function enhanceSlsa ({
|
|
471
|
-
if (
|
|
470
|
+
function enhanceSlsa ({provenance}) {
|
|
471
|
+
if (provenance) {
|
|
472
472
|
return {
|
|
473
473
|
badges: {
|
|
474
474
|
status: {
|
|
@@ -485,11 +485,21 @@ function enhanceSlsa ({packageDetails: {publishConfig: {access, provenance}}}) {
|
|
|
485
485
|
return {};
|
|
486
486
|
}
|
|
487
487
|
|
|
488
|
-
async function
|
|
489
|
-
|
|
488
|
+
async function liftProvenance ({projectRoot, packageDetails}) {
|
|
489
|
+
const {publishConfig: {access}} = packageDetails;
|
|
490
|
+
|
|
491
|
+
if ('public' === access) {
|
|
492
|
+
await mergeIntoExistingPackageJson({projectRoot, config: {publishConfig: {provenance: true}}});
|
|
493
|
+
|
|
494
|
+
return enhanceSlsa({provenance: true});
|
|
495
|
+
}
|
|
490
496
|
|
|
497
|
+
return {};
|
|
498
|
+
}
|
|
499
|
+
|
|
500
|
+
async function liftPublishable ({projectRoot, packageDetails}) {
|
|
491
501
|
return deepmerge(
|
|
492
|
-
|
|
502
|
+
await liftProvenance({packageDetails, projectRoot}),
|
|
493
503
|
{devDependencies: ['publint'], scripts: {'lint:publish': 'publint --strict'}}
|
|
494
504
|
);
|
|
495
505
|
}
|