cosmology-tech / telescope

A TypeScript Transpiler for Cosmos Protobufs ⚛️
https://cosmology.zone/products/telescope
Apache License 2.0
145 stars 43 forks source link

Docs for telescope download #691

Open Zetazzz opened 2 weeks ago

Zetazzz commented 2 weeks ago

Add docs to readme for the function telescope download then we can release.

Here's a simple one:

telescope transpile requires the proto files (from the install @protobufs/) in the same place. Is it possible for me to do glob searching? like --protoDirs=./proto,../proto/* . This way I don't have to copy paste over my proto files to the nested generated

about this. Hope this new function can help.

Create the config file ".protod.config.json":

{ "repos": [ { "owner": "cosmos", "repo": "cosmos-sdk", "branch": "release/v0.50.x" }, { "owner": "cosmos", "repo": "ibc-go" }, { "owner": "injectivelabs", "repo": "sdk-go" } ], "protoDirMapping": { "gogo/protobuf/master": ".", "googleapis/googleapis/master": ".", "protocolbuffers/protobuf/main": "src" }, "outDir": "protos", "ssh": true, "tempRepoDir": "git-modules", "targets": [ "cosmos/auth/v1beta1/auth.proto", ] }

telescope download --config ./path/to/.protod.config.json

target can be patterns:

      "cosmos/bank/v1beta1/tx.proto",
      "cosmos/gov/**/*.proto",
      "cosmos/authz/**/*.proto",