cli: add support for trimming next entry

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
This commit is contained in:
Patrik Oldsberg
2024-09-27 16:51:51 +02:00
parent 2e32ba5031
commit cebee4f9a9
2 changed files with 10 additions and 0 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/cli': patch
---
Added support for a new experimental `EXPERIMENTAL_TRIM_NEXT_ENTRY` flag which removes any `./next` entry points present in packages when building and publishing.
+5
View File
@@ -67,6 +67,11 @@ export function readEntryPoints(pkg: BackstagePackageJson): Array<EntryPoint> {
);
}
// Setting the EXPERIMENTAL_TRIM_NEXT_ENTRY flag will remove any `./next` entry points
if (process.env.EXPERIMENTAL_TRIM_NEXT_ENTRY && mount === './next') {
continue;
}
entryPoints.push(parseEntryPoint(mount, path));
}