scripts: fix package detection in check-if-release.js

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
This commit is contained in:
Patrik Oldsberg
2021-06-11 13:50:58 +02:00
parent 94fa652dbc
commit 150ab3ebb5
+4 -3
View File
@@ -58,10 +58,11 @@ async function main() {
'diff',
'--name-only',
parentRef,
"'packages/*/package.json'",
"'plugins/*/package.json'",
"'*/package.json'", // Git treats this as what would usually be **/package.json
);
const packageList = diff.split(/^(.*)$/gm).filter(s => s.trim());
const packageList = diff
.split('\n')
.filter(path => path.match(/^(packages|plugins)\/[^/]+\/package\.json$/));
const packageVersions = await Promise.all(
packageList.map(async path => {