@dxos/cli 2.20.2-dev.837d2962 → 2.20.2-dev.a7d91e29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -10
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -156,17 +156,9 @@ While developing a specific cli extension as a package in the monorepo, `rushx b
|
|
|
156
156
|
|
|
157
157
|
### Running commands locally
|
|
158
158
|
|
|
159
|
-
During local development there is a need for testing of a newly created/modified commands.
|
|
160
|
-
For that purpose, any cli command could be called from the repo root via `pnpm run dx`, e.g.:
|
|
159
|
+
During local development there is a need for testing of a newly created/modified commands. There also might be a need for the command to be called from the specific path (e.g. during app deployent).
|
|
161
160
|
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
```bash
|
|
165
|
-
pnpm run dx dxns resource list -- --json
|
|
166
|
-
```
|
|
167
|
-
|
|
168
|
-
If the command ought to be called from the specific path (e.g. during app deployent),
|
|
169
|
-
an alias for the local dx binary coud be created by adding such to the shell profile:
|
|
161
|
+
For such cases, an alias for the local dx binary coud be created by adding such to the shell profile:
|
|
170
162
|
|
|
171
163
|
```bash
|
|
172
164
|
`eval $(./scripts/dev.sh)`
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dxos/cli",
|
|
3
|
-
"version": "2.20.2-dev.
|
|
3
|
+
"version": "2.20.2-dev.a7d91e29",
|
|
4
4
|
"description": "DXOS CLI",
|
|
5
5
|
"homepage": "https://github.com/dxos/cli/tree/master/packages/cli#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"verbose": false
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@dxos/cli-core": "2.20.2-dev.
|
|
32
|
+
"@dxos/cli-core": "2.20.2-dev.a7d91e29",
|
|
33
33
|
"@dxos/client": "~2.32.0",
|
|
34
34
|
"@dxos/config": "~2.32.0",
|
|
35
35
|
"@dxos/debug": "~2.32.0",
|
|
@@ -95,5 +95,5 @@
|
|
|
95
95
|
"lint": "eslint './src/**/*.{ts,js}'",
|
|
96
96
|
"test": "NODE_ENV=test mocha -r @swc-node/register --exit './src/**/*.test.{ts,js}'"
|
|
97
97
|
},
|
|
98
|
-
"readme": "# DXOS CLI\n\nGeneral information about DXOS CLI can be found [here](../../README.md)\n\n## Usage\n\n### Profiles\n\nTo use the CLI, a profile needs to be created and activated.\n\nThe CLI supports creating multiple profiles with different configurations from downloadable templates, and switching between them.\n\nTo create a profile from a template, pass a profile name and template URL.\n\nExample:\n\n```bash\ndx profile init --name devnet --template-url https://bit.ly/3M37HBT\n```\n\nProfiles are stored in the `~/.dx/profile` folder. To further customize a profile, edit the profile configuration file.\n\nTo activate/use a profile, do one of the following (highest to lowest precedence):\n\n1. Pass it as an argument to a command (`--profile <NAME>`), e.g. `dx --profile devnet extension list`\n2. export `DX_PROFILE` in the shell, with the name of the profile, e.g. `export DX_PROFILE=devnet`\n3. Set it as the default for the system, e.g. `dx profile set devnet`\n\nNote: The first profile created automatically becomes the system default.\n\nView the name of the active profile:\n\n```bash\ndx profile\n```\n\nView the configuration values for the active profile:\n\n```bash\ndx profile config\n```\n\nView the configuration values for a given profile:\n\n```bash\ndx profile config <NAME>\n```\n\nView the profile used for a command (using the `--dry-run` flag):\n\n```bash\ndx extension list --dry-run\nProfile: /Users/ashwinp/.dx/profile/devnet.yml\n```\n\nMultiple templates can be created and shared with others to use different configuration values. \nSome [sample templates](./profiles/README.md) are included in the repo.\n\n### Extensions\n\nIn order to install CLI extensions, one could leverage automatic installation mechanism (for DXOS extensions only):\n\n```bash\ndx dxns\n```\n\n```bash\ndx app\n```\n\nIn order to install arbitrary extension, `dx extension install` command could be used:\n\n```\ndx extension install @dxos/cli-ipfs\n\n✔ Installing @dxos/cli-ipfs\n```\n\nView installed extensions:\n\n```\ndx extension list\n\nextension command version description\n-------------- ------- ------------ -----------------------\n@dxos/cli-app app 2.12.0 Application management.\n@dxos/cli-bot bot 2.12.0 Bot operations.\n@dxos/cli-ipfs ipfs 2.12.0 IPFS operations.\n```\n\nUninstall extension:\n\n```\ndx extension uninstall @dxos/cli-ipfs\n\nFound Extension @dxos/cli-ipfs@1.0.1-beta.2 installed, do you wish to remove it? (Yes/No): y\n✔ Uninstalling @dxos/cli-ipfs\n```\n\n#### Available Extensions\n\n| Extension |\n| :------------ |\n| [App CLI](../cli-app/README.md) |\n| [Bot CLI](../cli-bot/README.md) |\n| [Chat CLI](../cli-chat/README.md) |\n| [Console CLI](../cli-console/README.md) |\n| [Party CLI](../cli-party/README.md) |\n| [DXNS CLI](../cli-dxns/README.md) |\n| [ECHO CLI](../cli-echo/README.md) |\n| [HALO CLI](../cli-halo/README.md) |\n| [IPFS CLI](../cli-ipfs/README.md) |\n| [KUBE CLI](../cli-kube/README.md) |\n| [MDNS CLI](../cli-mdns/README.md) |\n| [Mesh CLI](../cli-mesh/README.md) |\n| [Signal CLI](../cli-signal/README.md) |\n\n#### Developing CLI extensions\n\nIn order to create a new CLI extension, existing CLI extension could be used as a boilerplate. \nWhile developing a new extension out of CLI Monorepo, make sure you add `@dxos/cli` as devDependency (and `@dxos/cli-party` as well if you are planning on using DXOS SDK Client).\n\n### Certification\n\nIn order for CLI to support custom certificate authorities, one would need to import root CA certificate using `dx cert import` command. For the case of XBOX, import command would look like:\n\n```bash\ndx cert import --url https://kube.local/kube.pem\n```\n\n<!--TODO(egor): Host cert on .well-known endpoint?-->\n\nCorresponding certificate would be downloaded to `~/.dx/certs` and considered by CLI as \"trusted\".\n\n## Development\n\n### Dependencies\n\n- [jq](https://stedolan.github.io/jq/)\n\n### Setup\n\n```bash\n# CLI is a yarn monorepo\n\n# Install dependencies\nrush update\n\n# Build all packages\nrush build\n```\n\n### Developing of a single extension\n\nWhile developing a specific cli extension as a package in the monorepo, `rushx build:watch` command is available from the root of this package.\n\n### Running commands locally\n\nDuring local development there is a need for testing of a newly created/modified commands.
|
|
98
|
+
"readme": "# DXOS CLI\n\nGeneral information about DXOS CLI can be found [here](../../README.md)\n\n## Usage\n\n### Profiles\n\nTo use the CLI, a profile needs to be created and activated.\n\nThe CLI supports creating multiple profiles with different configurations from downloadable templates, and switching between them.\n\nTo create a profile from a template, pass a profile name and template URL.\n\nExample:\n\n```bash\ndx profile init --name devnet --template-url https://bit.ly/3M37HBT\n```\n\nProfiles are stored in the `~/.dx/profile` folder. To further customize a profile, edit the profile configuration file.\n\nTo activate/use a profile, do one of the following (highest to lowest precedence):\n\n1. Pass it as an argument to a command (`--profile <NAME>`), e.g. `dx --profile devnet extension list`\n2. export `DX_PROFILE` in the shell, with the name of the profile, e.g. `export DX_PROFILE=devnet`\n3. Set it as the default for the system, e.g. `dx profile set devnet`\n\nNote: The first profile created automatically becomes the system default.\n\nView the name of the active profile:\n\n```bash\ndx profile\n```\n\nView the configuration values for the active profile:\n\n```bash\ndx profile config\n```\n\nView the configuration values for a given profile:\n\n```bash\ndx profile config <NAME>\n```\n\nView the profile used for a command (using the `--dry-run` flag):\n\n```bash\ndx extension list --dry-run\nProfile: /Users/ashwinp/.dx/profile/devnet.yml\n```\n\nMultiple templates can be created and shared with others to use different configuration values. \nSome [sample templates](./profiles/README.md) are included in the repo.\n\n### Extensions\n\nIn order to install CLI extensions, one could leverage automatic installation mechanism (for DXOS extensions only):\n\n```bash\ndx dxns\n```\n\n```bash\ndx app\n```\n\nIn order to install arbitrary extension, `dx extension install` command could be used:\n\n```\ndx extension install @dxos/cli-ipfs\n\n✔ Installing @dxos/cli-ipfs\n```\n\nView installed extensions:\n\n```\ndx extension list\n\nextension command version description\n-------------- ------- ------------ -----------------------\n@dxos/cli-app app 2.12.0 Application management.\n@dxos/cli-bot bot 2.12.0 Bot operations.\n@dxos/cli-ipfs ipfs 2.12.0 IPFS operations.\n```\n\nUninstall extension:\n\n```\ndx extension uninstall @dxos/cli-ipfs\n\nFound Extension @dxos/cli-ipfs@1.0.1-beta.2 installed, do you wish to remove it? (Yes/No): y\n✔ Uninstalling @dxos/cli-ipfs\n```\n\n#### Available Extensions\n\n| Extension |\n| :------------ |\n| [App CLI](../cli-app/README.md) |\n| [Bot CLI](../cli-bot/README.md) |\n| [Chat CLI](../cli-chat/README.md) |\n| [Console CLI](../cli-console/README.md) |\n| [Party CLI](../cli-party/README.md) |\n| [DXNS CLI](../cli-dxns/README.md) |\n| [ECHO CLI](../cli-echo/README.md) |\n| [HALO CLI](../cli-halo/README.md) |\n| [IPFS CLI](../cli-ipfs/README.md) |\n| [KUBE CLI](../cli-kube/README.md) |\n| [MDNS CLI](../cli-mdns/README.md) |\n| [Mesh CLI](../cli-mesh/README.md) |\n| [Signal CLI](../cli-signal/README.md) |\n\n#### Developing CLI extensions\n\nIn order to create a new CLI extension, existing CLI extension could be used as a boilerplate. \nWhile developing a new extension out of CLI Monorepo, make sure you add `@dxos/cli` as devDependency (and `@dxos/cli-party` as well if you are planning on using DXOS SDK Client).\n\n### Certification\n\nIn order for CLI to support custom certificate authorities, one would need to import root CA certificate using `dx cert import` command. For the case of XBOX, import command would look like:\n\n```bash\ndx cert import --url https://kube.local/kube.pem\n```\n\n<!--TODO(egor): Host cert on .well-known endpoint?-->\n\nCorresponding certificate would be downloaded to `~/.dx/certs` and considered by CLI as \"trusted\".\n\n## Development\n\n### Dependencies\n\n- [jq](https://stedolan.github.io/jq/)\n\n### Setup\n\n```bash\n# CLI is a yarn monorepo\n\n# Install dependencies\nrush update\n\n# Build all packages\nrush build\n```\n\n### Developing of a single extension\n\nWhile developing a specific cli extension as a package in the monorepo, `rushx build:watch` command is available from the root of this package.\n\n### Running commands locally\n\nDuring local development there is a need for testing of a newly created/modified commands. There also might be a need for the command to be called from the specific path (e.g. during app deployent).\n\nFor such cases, an alias for the local dx binary coud be created by adding such to the shell profile:\n\n```bash\n`eval $(./scripts/dev.sh)`\n```\n\nThen run `rushx build:watch` in for all packages that are being edited.\n\nRun `dx info` to check if the local version is being run.\n\nSet the `DEBUG` environment variable to `true` to see full exception traces on error.\n\n```bash\nDEBUG=dxos:cli dx\n````\n\n### Environment Variables\n\nWhile the usage of ENV variables is minimized, in some edge cases CLI still uses ENV variables for configuration. \nThose variables are mapped to the canonical structure: [ENV mapping](../cli-core/src/env-map.json)\n\nENV variables are also used to pass configuration between CLI and spawned processes, but this happens transparently for CLI user.\n\n## Troubleshooting\n\nMost of the weirdness in CLI behaviour could be caused by any combination of previously installed CLIs and extensions, especially from the beta channel;\n\nCheck latest available version:\n\n```bash\nyarn info @dxos/cli versions --json | jq '.data[-1]'\n```\n\nCheck installed version:\n\n```bash\ndx version\n```\n\nIf those outputs are different, make sure to remove old versions of `dx`.\nRemove old CLI and extensions, installed globally.\n\nFor that purpose `dx uninstall` and `dx upgrade` commands are available.\n\nTo remove CLI and all extensions:\n\n```bash\ndx uninstall --npm-client yarn\n```\n\nTo force upgrade CLI and all installed extensions to the latest:\n\n```bash\ndx upgrade --npm-client yarn --force\n```\n\n`--version` attribute could be supplied in order to upgrade/downgrade to a specific version.\n"
|
|
99
99
|
}
|