67c92b3e56
* Moved definition of mixnet contract common items to separate module * Removed schemars dependency from being wasm32 specific * Moved query responses to the shared module * Fixed tests due to differerent import paths * Updated dashmap in other crates to help with once_cell version selection * Reexporting coin and humanaddr * Deserializing response from validator * Deserializing smart result directly to specific type * Ability to query for mixnodes and gateways from rust * Fixed compilation warning due to updated dashmap
20 lines
684 B
Rust
20 lines
684 B
Rust
use cosmwasm_schema::{export_schema, remove_schemas, schema_for};
|
|
use mixnet_contract::MixNodeBond;
|
|
use mixnet_contracts::msg::{HandleMsg, InitMsg, QueryMsg};
|
|
use mixnet_contracts::state::State;
|
|
use std::env::current_dir;
|
|
use std::fs::create_dir_all;
|
|
|
|
fn main() {
|
|
let mut out_dir = current_dir().unwrap();
|
|
out_dir.push("schema");
|
|
create_dir_all(&out_dir).unwrap();
|
|
remove_schemas(&out_dir).unwrap();
|
|
|
|
export_schema(&schema_for!(InitMsg), &out_dir);
|
|
export_schema(&schema_for!(HandleMsg), &out_dir);
|
|
export_schema(&schema_for!(QueryMsg), &out_dir);
|
|
export_schema(&schema_for!(State), &out_dir);
|
|
export_schema(&schema_for!(MixNodeBond), &out_dir);
|
|
}
|