Skip to content

RHIDP-6966: use @red-hat-developer-hub/cli instead of @janus-idp/cli #1258

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 11, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion modules/dynamic-plugins/proc-create-plugin-js-package.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,6 @@ You can add the following to your `package.json` file before running the `export
}
----
If you modify `publishConfig` after exporting the dynamic plugin, re-run the `export-dynamic-plugin` command to ensure the correct configuration is included.
If you modify `publishConfig` after exporting the dynamic plugin, re-run the `plugin export` command to ensure the correct configuration is included.
====
--
2 changes: 1 addition & 1 deletion modules/dynamic-plugins/proc-create-plugin-oci-image.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
.Example command to package an exported third-party plugin
[source,terminal]
----
npx @janus-idp/cli@latest package package-dynamic-plugins --tag quay.io/example/image:v0.0.1
npx @red-hat-developer-hub/cli@latest plugin package --tag quay.io/example/image:v0.0.1
----

In the previous command, the `--tag` argument specifies the image name and tag.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
To use plugins in {product}, you can export plugins as derived dynamic plugin packages. These packages contain the plugin code and dependencies, ready for dynamic plugin integration into {product-short}.

.Prerequisites
* The `@janus-idp/cli` package is installed. Use the latest version (`@latest` tag) for compatibility with the most recent features and fixes.
* The `@red-hat-developer-hub/cli` package is installed. Use the latest version (`@latest` tag) for compatibility with the most recent features and fixes.
* Node.js and NPM is installed and configured.
* The third-party plugin is compatible with your {product} version. For more information, see link:https://github.com/redhat-developer/rhdh/blob/main/docs/dynamic-plugins/versions.md[Version compatibility matrix].
* The third-party plugin must have a valid `package.json` file in its root directory, containing all required metadata and dependencies.
Expand Down Expand Up @@ -35,7 +35,7 @@ The following is an example of exporting a dynamic plugin with shared and embedd
.Example dynamic plugin export with shared and embedded packages
[source,terminal]
----
npx @janus-idp/cli@latest export-dynamic-plugin --shared-package '!/@backstage/plugin-notifications/' --embed-package @backstage/plugin-notifications-backend
npx @red-hat-developer-hub/cli@latest plugin export --shared-package '!/@backstage/plugin-notifications/' --embed-package @backstage/plugin-notifications-backend
----
+
In the previous example:
Expand All @@ -51,7 +51,7 @@ Front-end plugins can use `scalprum` for configuration, which the CLI can genera
.Example command to log the default configuration
[source,terminal]
----
npx @janus-idp/cli@latest export-dynamic
npx @red-hat-developer-hub/cli@latest plugin export
----
+
The following is an example of default `scalprum` configuration:
Expand Down Expand Up @@ -105,13 +105,13 @@ export const DynamicEntityTechdocsContent = {
--

.Procedure
* Use the `package export-dynamic-plugin` command from the `@janus-idp/cli` package to export the plugin:
* Use the `plugin export` command from the `@red-hat-developer-hub/cli` package to export the plugin:
+
--
.Example command to export a third-party plugin
[source,terminal]
----
npx @janus-idp/cli@latest package export-dynamic-plugin
npx @red-hat-developer-hub/cli@latest plugin export
----

Ensure that you execute the previous command in the root directory of the plugin's JavaScript package (containing `package.json` file).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ $ yarn install
[source,terminal]
----
$ cd todo-backend
$ npx @janus-idp/cli@latest package export-dynamic-plugin
$ npx @red-hat-developer-hub/cli@latest plugin export
----

.Output of exporting the backend plugin commands
Expand Down Expand Up @@ -54,7 +54,7 @@ You can run the following commands to set default dynamic UI configurations, cre
[source,terminal]
----
$ cd ../todo
$ npx @janus-idp/cli@latest package export-dynamic-plugin
$ npx @red-hat-developer-hub/cli@latest plugin export
----

.Output of exporting the front-end plugin commands
Expand Down Expand Up @@ -87,7 +87,7 @@ Saving self-contained config schema in /Users/user/Code/community-plugins/worksp
[source,terminal]
----
$ cd ../..
$ npx @janus-idp/cli@latest package package-dynamic-plugins --tag quay.io/user/backstage-community-plugin-todo:v0.1.1
$ npx @red-hat-developer-hub/cli@latest plugin package --tag quay.io/user/backstage-community-plugin-todo:v0.1.1
----

.Output of building an OCI image commands
Expand Down
2 changes: 1 addition & 1 deletion modules/proc-create-plugin.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ The previous command creates a new plugin based on the provided ID. The plugin i
yarn workspace {pluginID} start # Also supports --check <1>
----

<1> ID of the new plugin such as `@janus-idp/my-new-plugin`
<1> ID of the new plugin such as `@red-hat-developer-hub/my-new-plugin`

Accessing the plugin in isolation results in quicker iteration and startup times. This approach is specifically for local development, and you can find the necessary configuration in the plugin's `dev/` directory.
--
6 changes: 3 additions & 3 deletions modules/techdocs/proc-techdocs-addon-install-third-party.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -26,18 +26,18 @@ yarn install
+
[source,terminal,subs="+quotes,+attributes"]
----
npx @janus-idp/cli@latest package export-dynamic-plugin
npx @red-hat-developer-hub/cli@latest plugin export
----
+
[NOTE]
====
The `@latest` tag pulls the latest version of the @janus-idp/cli package, which is compatible with the most recent features and fixes. Use a version that is compatible with your {product} version.
The `@latest` tag pulls the latest version of the @red-hat-developer-hub/cli package, which is compatible with the most recent features and fixes. Use a version that is compatible with your {product} version.
====
. To package the third-party TechDocs add-on as a dynamic plugin, navigate to the root directory where the plugin is stored (not the dist-dynamic directory) and run the `npx` command with the `--tag` option to specify the image name and tag. For example:
+
[source,terminal,subs="+quotes,+attributes"]
----
npx @janus-idp/cli@latest package package-dynamic-plugins --tag quay.io/_<user_name>_/_<techdocs_add-on_image>_:latest
npx @red-hat-developer-hub/cli@latest plugin package --tag quay.io/_<user_name>_/_<techdocs_add-on_image>_:latest
----
+
[NOTE]
Expand Down