aboutsummaryrefslogtreecommitdiffstats
path: root/build/WebpackSPDXPlugin.js
diff options
context:
space:
mode:
authorFerdinand Thiessen <opensource@fthiessen.de>2024-06-18 16:54:19 +0200
committerFerdinand Thiessen <opensource@fthiessen.de>2024-06-18 16:55:14 +0200
commitd67eb8ce4e9c98d66994e1c576627169c9e1b8fb (patch)
tree8c1dafee0740fd4d0e77606607d0020ef92536c1 /build/WebpackSPDXPlugin.js
parentc3208c1d56cb8dde13a998bd89122ef2d86ad60a (diff)
downloadnextcloud-server-d67eb8ce4e9c98d66994e1c576627169c9e1b8fb.tar.gz
nextcloud-server-d67eb8ce4e9c98d66994e1c576627169c9e1b8fb.zip
chore: Adjust SPDX tool to multiple line licenses instead of `AND` chained
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
Diffstat (limited to 'build/WebpackSPDXPlugin.js')
-rw-r--r--build/WebpackSPDXPlugin.js12
1 files changed, 8 insertions, 4 deletions
diff --git a/build/WebpackSPDXPlugin.js b/build/WebpackSPDXPlugin.js
index e9eeccca0f1..82ccfabf173 100644
--- a/build/WebpackSPDXPlugin.js
+++ b/build/WebpackSPDXPlugin.js
@@ -198,8 +198,11 @@ class WebpackSPDXPlugin {
authors.add(pkg.author)
output += `\n- ${pkg.name}\n\t- version: ${pkg.version}\n\t- license: ${license}`
}
- output += `\n\nSPDX-License-Identifier: ${[...licenses].sort().join(' AND ')}\n`
- output += [...authors].sort().map((author) => `SPDX-FileCopyrightText: ${author}`).join('\n');
+ output += '\n\n'
+ for (const license of [...licenses].sort()) {
+ output += `SPDX-License-Identifier: ${license}\n`
+ }
+ output += [...authors].sort().map((author) => `SPDX-FileCopyrightText: ${author}`).join('\n')
compilation.emitAsset(
asset.split('?', 2)[0] + '.license',
@@ -208,9 +211,10 @@ class WebpackSPDXPlugin {
}
if (callback) {
- return void callback()
+ return callback()
}
}
+
}
-module.exports = WebpackSPDXPlugin;
+module.exports = WebpackSPDXPlugin