@hyperweb/telescope 2.2.0 → 2.2.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
@@ -142,7 +142,7 @@ For detailed CLI `generate` commands, please refer to our documentation.
142
142
  You can download proto files using the `download-protos` command provided in the boilerplate:
143
143
 
144
144
  ```sh
145
- yarn download-protos
145
+ pnpm download-protos
146
146
  ```
147
147
 
148
148
  After running this command, you'll see:
@@ -153,10 +153,10 @@ These proto files are downloaded based on your configuration. For detailed CLI `
153
153
 
154
154
  ### Transpile
155
155
 
156
- To generate TypeScript files for your chain, run the `yarn codegen` command:
156
+ To generate TypeScript files for your chain, run the `pnpm codegen` command:
157
157
 
158
158
  ```sh
159
- yarn codegen
159
+ pnpm codegen
160
160
  ```
161
161
 
162
162
  ### Build
@@ -164,8 +164,8 @@ yarn codegen
164
164
  Finally, build your package to generate JavaScript files and TypeScript definitions:
165
165
 
166
166
  ```sh
167
- yarn install
168
- yarn build
167
+ pnpm install
168
+ pnpm build
169
169
  ```
170
170
 
171
171
  ### Publishing
@@ -374,28 +374,28 @@ Next, navigate to the `./your-project/packages/telescope` directory.
374
374
 
375
375
  Install dependencies and download the proto files you need:
376
376
  ```sh
377
- yarn install
377
+ pnpm install
378
378
  telescope download --config ./your.config.json
379
379
  ```
380
380
 
381
381
  Generate TypeScript files for your chain:
382
382
 
383
383
  ```sh
384
- yarn codegen
384
+ pnpm codegen
385
385
  ```
386
386
 
387
387
  ### Manual Install
388
388
 
389
389
  To use Telescope in an existing project, run the following command in your project directory:
390
390
  ```sh
391
- yarn add --dev @hyperweb/telescope
391
+ pnpm add --save-dev @hyperweb/telescope
392
392
  ```
393
393
  Also install the required helpers and CosmJS [dependencies listed here](#dependencies).
394
394
 
395
395
  We recommend using [Programmatic Usage](#programmatic-usage) for better integration.
396
396
 
397
- You can also use the [Telescope CLI](#telescope-cli). When using CLI commands within your project, prefix them with `npx` or `yarn`. For example:
398
- - `yarn telescope generate`
397
+ You can also use the [Telescope CLI](#telescope-cli). When using CLI commands within your project, prefix them with `npx` or `pnpm`. For example:
398
+ - `pnpm telescope generate`
399
399
  - `npx telescope download`
400
400
 
401
401
  ### Programmatic Usage
@@ -403,7 +403,7 @@ You can also use the [Telescope CLI](#telescope-cli). When using CLI commands wi
403
403
  First add telescope to your `devDependencies`:
404
404
 
405
405
  ```sh
406
- yarn add --dev @hyperweb/telescope
406
+ pnpm add --save-dev @hyperweb/telescope
407
407
  ```
408
408
 
409
409
  Install the required helpers and CosmJS [dependencies listed here](#dependencies).
@@ -1504,7 +1504,7 @@ If you don't use the boilerplate, you will need to manually install
1504
1504
  * `@cosmjs/tendermint-rpc`
1505
1505
 
1506
1506
  ```sh
1507
- yarn add @cosmjs/amino @cosmjs/proto-signing @cosmjs/stargate @cosmjs/tendermint-rpc
1507
+ pnpm add @cosmjs/amino @cosmjs/proto-signing @cosmjs/stargate @cosmjs/tendermint-rpc
1508
1508
  ```
1509
1509
 
1510
1510
  If you use the LCD Client generation, you'll need to add
@@ -1512,7 +1512,7 @@ If you use the LCD Client generation, you'll need to add
1512
1512
  * `@cosmology/lcd`
1513
1513
 
1514
1514
  ```sh
1515
- yarn add @cosmology/lcd
1515
+ pnpm add @cosmology/lcd
1516
1516
  ```
1517
1517
 
1518
1518
  ## Troubleshooting
@@ -1,8 +1,9 @@
1
1
  import { join, dirname } from "path";
2
2
  import { mkdirp } from "mkdirp";
3
- import pkg from "../../package.json";
3
+ import { findAndRequirePackageJson } from "find-and-require-package-json";
4
4
  import { writeContentToFile } from "../utils/files";
5
5
  import { external, externalComet, externalIcJs, getHelper, getHelperForBigint, getReactQueryHelper, getVueQueryHelperHooks, mobx, grpcGateway, grpcWeb, pinia, varint, utf8, getHelperForBinary, getRegistryHelper, getTypesHelper, jsonSafe, decimal, getHelperFuncTypes, getHelperFuncTypesForInterface, getReactQueryHelperHooks, getReactQueryHelperHooksIcJs, } from "../helpers";
6
+ const pkg = findAndRequirePackageJson(__dirname);
6
7
  const version = process.env.NODE_ENV === "test" ? "latest" : pkg.version;
7
8
  const header = `/**
8
9
  * This file and any referenced files were automatically generated by ${pkg.name}@${version}
@@ -3,9 +3,9 @@ import { join, dirname } from "path";
3
3
  import { mkdirp } from "mkdirp";
4
4
  import * as t from "@babel/types";
5
5
  import generate from "@babel/generator";
6
- //@ts-ignore
7
- import pkg from "../../package.json";
6
+ import { findAndRequirePackageJson } from "find-and-require-package-json";
8
7
  import { writeContentToFile } from "../utils/files";
8
+ const pkg = findAndRequirePackageJson(__dirname);
9
9
  const version = process.env.NODE_ENV === "test" ? "latest" : pkg.version;
10
10
  export const plugin = (builder) => {
11
11
  if (!builder.options.bundle.enabled) {
@@ -1,17 +1,15 @@
1
1
  "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
2
  Object.defineProperty(exports, "__esModule", { value: true });
6
3
  exports.plugin = void 0;
7
4
  const path_1 = require("path");
8
5
  const mkdirp_1 = require("mkdirp");
9
- const package_json_1 = __importDefault(require("../../package.json"));
6
+ const find_and_require_package_json_1 = require("find-and-require-package-json");
10
7
  const files_1 = require("../utils/files");
11
8
  const helpers_1 = require("../helpers");
12
- const version = process.env.NODE_ENV === "test" ? "latest" : package_json_1.default.version;
9
+ const pkg = (0, find_and_require_package_json_1.findAndRequirePackageJson)(__dirname);
10
+ const version = process.env.NODE_ENV === "test" ? "latest" : pkg.version;
13
11
  const header = `/**
14
- * This file and any referenced files were automatically generated by ${package_json_1.default.name}@${version}
12
+ * This file and any referenced files were automatically generated by ${pkg.name}@${version}
15
13
  * DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
16
14
  * and run the transpile command or npm scripts command that is used to regenerate this bundle.
17
15
  */
@@ -42,10 +42,10 @@ const path_1 = require("path");
42
42
  const mkdirp_1 = require("mkdirp");
43
43
  const t = __importStar(require("@babel/types"));
44
44
  const generator_1 = __importDefault(require("@babel/generator"));
45
- //@ts-ignore
46
- const package_json_1 = __importDefault(require("../../package.json"));
45
+ const find_and_require_package_json_1 = require("find-and-require-package-json");
47
46
  const files_1 = require("../utils/files");
48
- const version = process.env.NODE_ENV === "test" ? "latest" : package_json_1.default.version;
47
+ const pkg = (0, find_and_require_package_json_1.findAndRequirePackageJson)(__dirname);
48
+ const version = process.env.NODE_ENV === "test" ? "latest" : pkg.version;
49
49
  const plugin = (builder) => {
50
50
  if (!builder.options.bundle.enabled) {
51
51
  return;
@@ -58,7 +58,7 @@ const plugin = (builder) => {
58
58
  const indexContent = (0, generator_1.default)(finalAst).code;
59
59
  mkdirp_1.mkdirp.sync((0, path_1.dirname)(indexOutFile));
60
60
  const header = `/**
61
- * This file and any referenced files were automatically generated by ${package_json_1.default.name}@${version}
61
+ * This file and any referenced files were automatically generated by ${pkg.name}@${version}
62
62
  * DO NOT MODIFY BY HAND. Instead, download the latest proto files for your chain
63
63
  * and run the transpile command or npm scripts command that is used to regenerate this bundle.
64
64
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hyperweb/telescope",
3
- "version": "2.2.0",
3
+ "version": "2.2.1",
4
4
  "description": "A TypeScript Transpiler for Cosmos Protobufs",
5
5
  "author": "Constructive <developers@constructive.io>",
6
6
  "homepage": "https://github.com/hyperweb-io/telescope",
@@ -79,6 +79,7 @@
79
79
  "dargs": "7.0.0",
80
80
  "deepmerge": "4.3.1",
81
81
  "dotty": "0.1.2",
82
+ "find-and-require-package-json": "^0.9.1",
82
83
  "fuzzy": "0.1.3",
83
84
  "glob": "8.0.3",
84
85
  "inquirerer": "0.1.3",
@@ -91,5 +92,5 @@
91
92
  "shelljs": "^0.8.5",
92
93
  "yaml": "^2.3.4"
93
94
  },
94
- "gitHead": "f58cb9dc265e15cb322855d98b88bdb5632a6c76"
95
+ "gitHead": "92f1ea27a7622a640c91facc480d85fb1c58bc6b"
95
96
  }