polkadot-cli 0.1.0 → 0.1.1

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 CHANGED
@@ -7,7 +7,7 @@ Ships with Polkadot as the default chain. Add any Substrate-based chain by point
7
7
  ## Install
8
8
 
9
9
  ```bash
10
- npm install -g polkadot-cli
10
+ npm install -g polkadot-cli@latest
11
11
  ```
12
12
 
13
13
  This installs the `dot` command globally.
package/dist/cli.mjs CHANGED
@@ -726,7 +726,7 @@ registerInspectCommand(cli);
726
726
  registerQueryCommand(cli);
727
727
  registerConstCommand(cli);
728
728
  cli.help();
729
- cli.version("0.1.0");
729
+ cli.version("0.1.1");
730
730
  function handleError(err) {
731
731
  if (err instanceof CliError2) {
732
732
  console.error(`Error: ${err.message}`);
@@ -739,7 +739,10 @@ function handleError(err) {
739
739
  }
740
740
  process.on("unhandledRejection", handleError);
741
741
  try {
742
- cli.parse();
742
+ const parsed = cli.parse();
743
+ if (parsed.args.length === 0 && !parsed.options.help && !parsed.options.version) {
744
+ cli.outputHelp();
745
+ }
743
746
  } catch (err) {
744
747
  handleError(err);
745
748
  }
package/package.json CHANGED
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "polkadot-cli",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "CLI tool for querying Polkadot-ecosystem on-chain state",
5
5
  "type": "module",
6
6
  "bin": {
7
- "dot": "./dist/cli.mjs"
7
+ "dot": "dist/cli.mjs"
8
8
  },
9
9
  "files": [
10
10
  "dist"
@@ -29,7 +29,7 @@
29
29
  ],
30
30
  "repository": {
31
31
  "type": "git",
32
- "url": "https://github.com/peetzweg/polkadot-cli"
32
+ "url": "git+https://github.com/peetzweg/polkadot-cli.git"
33
33
  },
34
34
  "dependencies": {
35
35
  "cac": "^6.7.14",