@citolab/tspci-tao 2.11.0 → 2.12.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/CHANGELOG.md +11 -0
- package/package.json +2 -2
- package/readme.md +11 -4
- package/release-notes.md +6 -0
- package/src/createPackage.mjs +14 -10
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,17 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# [2.12.0](https://github.com/Citolab/tspci/compare/v2.11.0...v2.12.0) (2026-08-19)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* include the SBOM in the exported package by default ([376b89a](https://github.com/Citolab/tspci/commit/376b89a5651bb9a420fbd2973d221a7e5200bd35))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
6
17
|
# [2.11.0](https://github.com/Citolab/tspci/compare/v2.10.0...v2.11.0) (2026-08-19)
|
|
7
18
|
|
|
8
19
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@citolab/tspci-tao",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.12.0",
|
|
4
4
|
"description": "create a zip file that can be imported into TAO",
|
|
5
5
|
"author": "patrick <patrick.deklein@cito.nl>, Marcel Hoekstra <marcel.hoekstra@cito.nl>",
|
|
6
6
|
"repository": "",
|
|
@@ -16,5 +16,5 @@
|
|
|
16
16
|
"access": "public",
|
|
17
17
|
"registry": "https://registry.npmjs.org/"
|
|
18
18
|
},
|
|
19
|
-
"gitHead": "
|
|
19
|
+
"gitHead": "eb7676525e9bf75daa9b2f42f035faed9b8e9a70"
|
|
20
20
|
}
|
package/readme.md
CHANGED
|
@@ -134,7 +134,14 @@ Add a svg file with the name {typeIdentifier}.svg in the root of the PCI directo
|
|
|
134
134
|
|
|
135
135
|
## sbom
|
|
136
136
|
|
|
137
|
-
A CycloneDX SBOM of the bundle is
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
137
|
+
A CycloneDX SBOM of the bundle is included in the package as `interaction/runtime/js/sbom.cdx.json`,
|
|
138
|
+
next to the bundle it describes, and copied next to the zip in `dist/` as
|
|
139
|
+
`tao-pci-<typeIdentifier>_<version>.sbom.cdx.json` for your own technical documentation.
|
|
140
|
+
|
|
141
|
+
Note that `imsPciCreator.json` does not list the SBOM in `runtime.src`. It travels with the zip you hand
|
|
142
|
+
over, but whether TAO keeps the file after registering the PCI is untested: TAO copies the files from
|
|
143
|
+
the src lists. Adding it there is a one line change, but a rejected registration is worse than a missing
|
|
144
|
+
file, so that is not done by default.
|
|
145
|
+
|
|
146
|
+
Use `--no-include-sbom` to keep it out of the package, or `--no-sbom` to skip generating one. See
|
|
147
|
+
[@citolab/tspci](https://github.com/Citolab/tspci/tree/main/lib/tspci#sbom) for the configuration.
|
package/release-notes.md
CHANGED
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
# 2.12.0
|
|
2
|
+
|
|
3
|
+
- the SBOM is included in the package as `interaction/runtime/js/sbom.cdx.json`, next to the bundle
|
|
4
|
+
- it is not listed in `runtime.src` of `imsPciCreator.json`, so whether TAO keeps the file after registering the PCI is untested
|
|
5
|
+
- `--no-include-sbom` keeps it out of the package
|
|
6
|
+
|
|
1
7
|
# 2.11.0
|
|
2
8
|
|
|
3
9
|
- a CycloneDX SBOM of the bundle is copied next to the zip in `dist/` as `tao-pci-<typeIdentifier>_<version>.sbom.cdx.json`
|
package/src/createPackage.mjs
CHANGED
|
@@ -330,11 +330,13 @@ export const bundle = () => {
|
|
|
330
330
|
}
|
|
331
331
|
// console.log(propertiesToReplace.short)
|
|
332
332
|
|
|
333
|
-
// SBOM:
|
|
333
|
+
// SBOM: shipped inside the package next to the bundle it describes, and
|
|
334
|
+
// copied next to the package for your own technical documentation
|
|
334
335
|
handleSbom({
|
|
335
336
|
distDirectory: path.join(PACKAGE_ROOT_PATH, path.dirname((packageData.main || "dist/index.js").replace(/^\//, ""))),
|
|
336
337
|
outputDirectory,
|
|
337
338
|
packageTempDirectory: outputDirectoryTemp,
|
|
339
|
+
packageDirectory: path.posix.join("interaction", "runtime", "js"),
|
|
338
340
|
baseName: `tao-pci-${propertiesToReplace.typeIdentifier}_${packageData.version}`,
|
|
339
341
|
packageData,
|
|
340
342
|
});
|
|
@@ -436,11 +438,12 @@ function isBoolean(val) {
|
|
|
436
438
|
}
|
|
437
439
|
}
|
|
438
440
|
|
|
439
|
-
// The
|
|
440
|
-
//
|
|
441
|
-
//
|
|
442
|
-
//
|
|
443
|
-
|
|
441
|
+
// The SBOM travels inside the package, because a file next to the zip does not
|
|
442
|
+
// survive an import into another system, and that is exactly the party that
|
|
443
|
+
// needs it. A copy is left next to the package for your own technical
|
|
444
|
+
// documentation. Use --no-include-sbom (or config.tspci.sbom.includeInPackage:
|
|
445
|
+
// false) to keep it out of the package, and --no-sbom to skip it altogether.
|
|
446
|
+
function handleSbom({ distDirectory, outputDirectory, packageTempDirectory, packageDirectory, baseName, packageData }) {
|
|
444
447
|
const settings = packageData?.config?.tspci?.sbom || {};
|
|
445
448
|
if (settings.enabled === false || process.argv.includes("--no-sbom")) {
|
|
446
449
|
return "";
|
|
@@ -454,10 +457,11 @@ function handleSbom({ distDirectory, outputDirectory, packageTempDirectory, base
|
|
|
454
457
|
fs.copyFileSync(source, path.join(outputDirectory, `${baseName}.${fileName}`));
|
|
455
458
|
console.log(`created sbom: ${baseName}.${fileName}`);
|
|
456
459
|
|
|
457
|
-
|
|
458
|
-
if (!includeInPackage) {
|
|
460
|
+
if (settings.includeInPackage === false || process.argv.includes("--no-include-sbom")) {
|
|
459
461
|
return "";
|
|
460
462
|
}
|
|
461
|
-
|
|
462
|
-
|
|
463
|
+
const target = packageDirectory ? path.join(packageTempDirectory, packageDirectory) : packageTempDirectory;
|
|
464
|
+
fs.mkdirSync(target, { recursive: true });
|
|
465
|
+
fs.copyFileSync(source, path.join(target, fileName));
|
|
466
|
+
return packageDirectory ? path.posix.join(packageDirectory, fileName) : fileName;
|
|
463
467
|
}
|