Skip to content

Commit 7289787

Browse files
committed
[Playground CLI] Consolidate auto mounting logic
1 parent 121a8bc commit 7289787

File tree

6 files changed

+721
-290
lines changed

6 files changed

+721
-290
lines changed

packages/playground/blueprints/src/lib/compile.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,10 @@ export interface CompileBlueprintOptions {
8181
* A filesystem to use for the blueprint.
8282
*/
8383
streamBundledFile?: StreamBundledFile;
84+
/**
85+
* Additional steps to add to the blueprint.
86+
*/
87+
additionalSteps?: any[];
8488
}
8589

8690
export async function compileBlueprint(
@@ -135,6 +139,7 @@ function compileBlueprintJson(
135139
onStepCompleted = () => {},
136140
corsProxy,
137141
streamBundledFile,
142+
additionalSteps,
138143
}: CompileBlueprintOptions = {}
139144
): CompiledBlueprint {
140145
blueprint = structuredClone(blueprint);
@@ -145,6 +150,9 @@ function compileBlueprintJson(
145150
.filter(isStepDefinition)
146151
.filter(isStepStillSupported),
147152
};
153+
154+
blueprint.steps = [...(blueprint.steps || []), ...(additionalSteps || [])];
155+
148156
for (const step of blueprint.steps!) {
149157
if (!step || typeof step !== 'object') {
150158
continue;

packages/playground/cli/src/cli-auto-mount.ts

Lines changed: 0 additions & 190 deletions
This file was deleted.

packages/playground/cli/src/mount.ts

Lines changed: 0 additions & 85 deletions
This file was deleted.

0 commit comments

Comments
 (0)