diff --git a/.changeset/tricky-toys-teach.md b/.changeset/tricky-toys-teach.md new file mode 100644 index 0000000000..f19b907682 --- /dev/null +++ b/.changeset/tricky-toys-teach.md @@ -0,0 +1,7 @@ +--- +'@backstage/create-app': patch +--- + +Remove deprecated `create-plugin` script from the `default-app` template's `package.json.hbs`. +Also, update the documentation to not mention the `create-plugin` script and instead mention +the `new` script. diff --git a/docs/assets/getting-started/create-plugin_output.png b/docs/assets/getting-started/create-plugin_output.png index 47231c2079..78389fa02f 100644 Binary files a/docs/assets/getting-started/create-plugin_output.png and b/docs/assets/getting-started/create-plugin_output.png differ diff --git a/docs/getting-started/contributors.md b/docs/getting-started/contributors.md index cda53f8a54..b6a12be013 100644 --- a/docs/getting-started/contributors.md +++ b/docs/getting-started/contributors.md @@ -116,7 +116,7 @@ yarn clean # Remove all output folders and @backstage/cli cache yarn diff # Make sure all plugins are up to date with the latest plugin template -yarn create-plugin # Create a new plugin +yarn new # Create a new module ``` > See diff --git a/docs/getting-started/project-structure.md b/docs/getting-started/project-structure.md index 858f0d8370..7873613a7b 100644 --- a/docs/getting-started/project-structure.md +++ b/docs/getting-started/project-structure.md @@ -101,7 +101,7 @@ are separated out into their own folder, see further down. - [`cli/`](https://github.com/backstage/backstage/tree/master/packages/cli) - One of the biggest packages in our project, the `cli` is used to build, serve, - diff, create-plugins and more. In the early days of this project, we started + diff, create plugins and more. In the early days of this project, we started out with calling tools directly - such as `eslint` - through `package.json`. But as it was tricky to have a good development experience around that when we change named tooling, we opted for wrapping those in our own CLI. That way diff --git a/docs/local-dev/cli-commands.md b/docs/local-dev/cli-commands.md index 715d586545..b43825d733 100644 --- a/docs/local-dev/cli-commands.md +++ b/docs/local-dev/cli-commands.md @@ -201,15 +201,15 @@ Usage: backstage-cli package postpack [options] Restores the changes made by the prepack command ``` -## create +## new -The `create` command opens up an interactive guide for you to create new things +The `new` command opens up an interactive guide for you to create new things in your app. If you do not pass in any options it is completely interactive, but it is possible to pre-select what you want to create using the `--select` flag, -and provide options using `--options`, for example: +and provide options using `--option`, for example: ```bash -backstage-cli create --select plugin --option id=foo +backstage-cli new --select plugin --option id=foo ``` This command is typically added as script in the root `package.json` to be diff --git a/docs/plugins/backend-plugin.md b/docs/plugins/backend-plugin.md index 65a668d391..517779d161 100644 --- a/docs/plugins/backend-plugin.md +++ b/docs/plugins/backend-plugin.md @@ -28,7 +28,7 @@ lowercase characters separated by dashes, for example `carmen`, if it's a package that adds an integration with a system named Carmen, for example. The full NPM package name would then be something like `@internal/plugin-carmen-backend`, depending on the other flags passed to the -`create-plugin` command, and your settings for the `create-plugin` command in +`new` command, and your settings for the `new` command in your root `package.json`. Creating the plugin will take a little while, so be patient. It will helpfully diff --git a/docs/plugins/create-a-plugin.md b/docs/plugins/create-a-plugin.md index 29607af140..da7cf0051a 100644 --- a/docs/plugins/create-a-plugin.md +++ b/docs/plugins/create-a-plugin.md @@ -11,7 +11,7 @@ A Backstage Plugin adds functionality to Backstage. To create a new plugin, make sure you've run `yarn install` and installed dependencies, then run the following on your command line (a shortcut to invoking the -[`backstage-cli create-plugin`](../local-dev/cli-commands.md#create-plugin)) +[`backstage-cli new --select plugin`](../local-dev/cli-commands.md#new)) from the root of your project. ```bash diff --git a/docs/plugins/integrating-plugin-into-software-catalog.md b/docs/plugins/integrating-plugin-into-software-catalog.md index 97efa56ac3..a44e6d01c0 100644 --- a/docs/plugins/integrating-plugin-into-software-catalog.md +++ b/docs/plugins/integrating-plugin-into-software-catalog.md @@ -21,7 +21,7 @@ should have a separate package in a folder, which represents your plugin. Example: ``` -$ yarn create-plugin +$ yarn new --select plugin > ? Enter an ID for the plugin [required] my-plugin > ? Enter the owner(s) of the plugin. If specified, this will be added to CODEOWNERS for the plugin path. [optional] diff --git a/docs/tutorials/journey.md b/docs/tutorials/journey.md index 126bb5ae0d..af78cbe597 100644 --- a/docs/tutorials/journey.md +++ b/docs/tutorials/journey.md @@ -28,7 +28,7 @@ organization to easily install and add to their Backstage installation. # 1. A New Plugin Sam chooses to develop this plugin in a standalone project and creates a new -plugin using `npx @backstage/cli create-plugin`, which detects that it's not +plugin using `npx @backstage/cli new --select plugin`, which detects that it's not being run in an existing project and therefore creates a separate plugin repo. Spinning up the frontend with `yarn start`, Sam goes to work with getting the diff --git a/docs/tutorials/quickstart-app-plugin.md b/docs/tutorials/quickstart-app-plugin.md index ea0a511c93..a1b30829b3 100644 --- a/docs/tutorials/quickstart-app-plugin.md +++ b/docs/tutorials/quickstart-app-plugin.md @@ -29,8 +29,8 @@ title: Adding Custom Plugin to Existing Monorepo App # The Skeleton Plugin -1. Start by using the built in creator. From the terminal and root of your - project run: `yarn create-plugin` +1. Start by using the built-in creator. From the terminal and root of your + project run: `yarn new --select plugin` 1. Enter a plugin ID. I used `github-playground` 1. When the process finishes, let's start the backend: `yarn --cwd packages/backend start` diff --git a/packages/create-app/templates/default-app/package.json.hbs b/packages/create-app/templates/default-app/package.json.hbs index 05c2436933..734de5c6e4 100644 --- a/packages/create-app/templates/default-app/package.json.hbs +++ b/packages/create-app/templates/default-app/package.json.hbs @@ -20,7 +20,6 @@ "lint": "backstage-cli repo lint --since origin/{{defaultBranch}}", "lint:all": "backstage-cli repo lint", "prettier:check": "prettier --check .", - "create-plugin": "backstage-cli create-plugin --scope internal", "new": "backstage-cli new --scope internal" }, "workspaces": {