From 632a6b217822f881fef7c1fdaa04545fb5f849a9 Mon Sep 17 00:00:00 2001 From: Himanshu Mishra Date: Thu, 7 Oct 2021 16:32:00 +0200 Subject: [PATCH] cli: use experimentalInstallationRecipe for new backstage-cli install command Signed-off-by: Himanshu Mishra --- .changeset/honest-drinks-eat.md | 2 +- .changeset/spicy-goats-help.md | 2 +- packages/cli/src/commands/install/install.ts | 2 +- packages/cli/src/commands/install/types.ts | 2 +- plugins/graphiql/package.json | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.changeset/honest-drinks-eat.md b/.changeset/honest-drinks-eat.md index 8d997acb61..b6cb168e00 100644 --- a/.changeset/honest-drinks-eat.md +++ b/.changeset/honest-drinks-eat.md @@ -2,4 +2,4 @@ '@backstage/plugin-graphiql': patch --- -Add experimental `installationRecipe` to `package.json`. +Add experimental `experimentalInstallationRecipe` to `package.json`. diff --git a/.changeset/spicy-goats-help.md b/.changeset/spicy-goats-help.md index 6c040ff6c9..44f1e96332 100644 --- a/.changeset/spicy-goats-help.md +++ b/.changeset/spicy-goats-help.md @@ -4,4 +4,4 @@ Add an experimental `install ` command. -Given a `pluginId`, the command looks for NPM packages matching `@backstage/plugin-{pluginId}` or `backstage-plugin-{pluginId}` or `{pluginId}`. It looks for the `installationRecipe` in their `package.json` for the steps of installation. Detailed documentation and API Spec to follow (and to be decided as well). +Given a `pluginId`, the command looks for NPM packages matching `@backstage/plugin-{pluginId}` or `backstage-plugin-{pluginId}` or `{pluginId}`. It looks for the `experimentalInstallationRecipe` in their `package.json` for the steps of installation. Detailed documentation and API Spec to follow (and to be decided as well). diff --git a/packages/cli/src/commands/install/install.ts b/packages/cli/src/commands/install/install.ts index 6117110f6e..2ec208bca3 100644 --- a/packages/cli/src/commands/install/install.ts +++ b/packages/cli/src/commands/install/install.ts @@ -67,7 +67,7 @@ class PluginInstaller { step: stepDefinitionMap.dependencies.create({ dependencies }), }); - for (const step of pkg.installationRecipe?.steps ?? []) { + for (const step of pkg.experimentalInstallationRecipe?.steps ?? []) { const { type } = step; const definition = stepDefinitions.find(d => d.type === type); diff --git a/packages/cli/src/commands/install/types.ts b/packages/cli/src/commands/install/types.ts index c75d147cfb..5479032de5 100644 --- a/packages/cli/src/commands/install/types.ts +++ b/packages/cli/src/commands/install/types.ts @@ -43,7 +43,7 @@ export type InstallationRecipe = { /** package.json data */ export type PackageWithInstallRecipe = YarnInfoInspectData & { version: string; - installationRecipe?: InstallationRecipe; + experimentalInstallationRecipe?: InstallationRecipe; }; export interface Step { diff --git a/plugins/graphiql/package.json b/plugins/graphiql/package.json index ffb238bd51..b2523bb3c1 100644 --- a/plugins/graphiql/package.json +++ b/plugins/graphiql/package.json @@ -61,7 +61,7 @@ "files": [ "dist" ], - "installationRecipe": { + "experimentalInstallationRecipe": { "type": "frontend-plugin", "steps": [ {