From 2581aa864b7b81698193e98e9fa1f563d5270b36 Mon Sep 17 00:00:00 2001 From: Loris Moulin <45130584+l0r1s@users.noreply.github.com> Date: Mon, 24 Apr 2023 19:29:11 +0300 Subject: [PATCH] docs: added convert command to documentation (#955) * docs: added convert command to documentation * docs: added convert to summary and fixed naming * chore: correct phrasing of convert description Co-authored-by: Nikos Kontakis --------- Co-authored-by: Nikos Kontakis --- docs/src/SUMMARY.md | 1 + docs/src/cli/convert.md | 24 ++++++++++++++++++++++++ 2 files changed, 25 insertions(+) create mode 100644 docs/src/cli/convert.md diff --git a/docs/src/SUMMARY.md b/docs/src/SUMMARY.md index 80e57d232..180d1784d 100644 --- a/docs/src/SUMMARY.md +++ b/docs/src/SUMMARY.md @@ -10,6 +10,7 @@ - [Podman](./features/podman.md) - [Native](./features/native.md) - [Cli usage](./cli/index.md) + - [Convert](./cli/convert.md) - [Setup](./cli/setup.md) - [Spawning](./cli/spawn.md) - [Using env vars](./cli/env_vars.md) diff --git a/docs/src/cli/convert.md b/docs/src/cli/convert.md new file mode 100644 index 000000000..5e2ce642f --- /dev/null +++ b/docs/src/cli/convert.md @@ -0,0 +1,24 @@ +# Convert + +The `convert` command is a CLI command designed to help users convert their a `Polkadot Launch` configuration to the ` Zombienet` configuration format. This tool is especially helpful for developers to migrate their projects to to Zombienet, without the need to manually rewrite their configurations. + +### Usage + +```bash +zombienet convert +``` + +**Note**: Where `````` is a Polkadot Launch configuration with a .js or .json extension defined by [this type](https://github.com/paritytech/polkadot-launch/blob/295a6870dd363b0b0108e745887f51e7141d7b5f/src/types.d.ts#L10) + +### Example + +Suppose you have a Polkadot Launch configuration file named `my-project-config.json`. To convert it to a Zombienet configuration file named `my-project-config-zombienet.json`, run: + +```bash +zombienet convert my-project-config.json +``` + +### Notes + +- The `convert` command will attempt to preserve as much information as possible from the original Polkadot Launch configuration file. However, due to the differences in the configuration structure and options between the two systems, some manual adjustments may be necessary after the conversion. +- It is recommended to thoroughly review the generated Zombienet configuration file to ensure that all the settings are correct and to make any necessary adjustments before using it to deploy your project. \ No newline at end of file