#module #injective #standard #cosmwasm #proto #cosmos-sdk #included

injective-std

Standard library for Injective with CosmWasm support included

12 releases ()

1.12.11-testnet-rc1 May 10, 2024
1.12.10-testnet-rc2 May 17, 2024
0.1.7 May 2, 2024
0.1.6 Mar 19, 2024
0.1.2 May 29, 2023

#1008 in Magic Beans

Download history 348/week @ 2024-02-11 181/week @ 2024-02-18 198/week @ 2024-02-25 174/week @ 2024-03-03 213/week @ 2024-03-10 380/week @ 2024-03-17 145/week @ 2024-03-24 184/week @ 2024-03-31 62/week @ 2024-04-07 110/week @ 2024-04-14 170/week @ 2024-04-21 379/week @ 2024-04-28 204/week @ 2024-05-05 272/week @ 2024-05-12 230/week @ 2024-05-19 79/week @ 2024-05-26

831 downloads per month
Used in 2 crates

MIT/Apache

780KB
13K SLoC

injective-std

BETA VERSION:

The bindings are currently tracking an unofficial release of Injective.

Injective's proto-generated types and helpers built using Buf. Enables interaction with both custom and standard modules.

Supported Version

  • Injective-Core@aa61552b5225f76f284811004925d83531e23311

Build Instructions

Pre-requisites:

Buf 1.17.0

In order to generate an individual proto file run:

buf generate [/path/to/injective-core] --template [/path/to/buf.gen.yaml] --output [output-path] --path [/path/to/module/proto]

Follow by:

buf build [/path/to/injective-core] --as-file-descriptor-set -o [/tmp/path/injective/descriptor_injective.bin] --path [/path/to/module/proto]

Example buf.gen.yaml file:

plugins:
  - plugin: buf.build/community/neoeinstein-prost
    out: .
    opt:
      - extern_path=.google.protobuf.Timestamp=crate::shim::Timestamp
      - extern_path=.google.protobuf.Duration=crate::shim::Duration
      - extern_path=.google.protobuf.Any=crate::shim::Any

Examples

Lets try to create the bindings for

First create a directory with the dependencies as below:

├── README.md
└── dependencies
    ├── cosmos-sdk
    ├── injective-core
    └── wasmd

Next generate the proto:

buf generate /Users/wandlitz/go/src/github.com/osmosis-labs/osmosis-rust/packages/proto-build-injective/../../dependencies/injective-core/proto --template /Users/wandlitz/go/src/github.com/osmosis-labs/osmosis-rust/packages/proto-build-injective/buf.gen.yaml --output ./tmp/tmp-protobuf/injective --path /Users/wandlitz/go/src/github.com/osmosis-labs/osmosis-rust/packages/proto-build-injective/../../dependencies/injective-core/proto/injective/auction
buf build /Users/wandlitz/go/src/github.com/osmosis-labs/osmosis-rust/packages/proto-build-injective/../../dependencies/injective-core/proto  --path /Users/wandlitz/go/src/github.com/osmosis-labs/osmosis-rust/packages/proto-build-injective/../../dependencies/injective-core/proto/injective/auction

Dependencies

~5–7MB
~146K SLoC