Skip to content

Commit

Permalink
feat: neutron-voting-registry new schema
Browse files Browse the repository at this point in the history
  • Loading branch information
ratik committed Aug 15, 2023
1 parent ec4bc75 commit 8573074
Show file tree
Hide file tree
Showing 14 changed files with 686 additions and 21 deletions.
18 changes: 6 additions & 12 deletions contracts/dao/voting/neutron-vault/examples/schema.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,14 @@
// See the License for the specific language governing permissions and
// limitations under the License.

use std::env::current_dir;
use std::fs::create_dir_all;

use cosmwasm_schema::{export_schema, remove_schemas, schema_for};
use cosmwasm_schema::write_api;

use neutron_vault::msg::{ExecuteMsg, InstantiateMsg, QueryMsg};

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!(InstantiateMsg), &out_dir);
export_schema(&schema_for!(ExecuteMsg), &out_dir);
export_schema(&schema_for!(QueryMsg), &out_dir);
write_api! {
instantiate: InstantiateMsg,
query: QueryMsg,
execute: ExecuteMsg,
}
}
Loading

0 comments on commit 8573074

Please sign in to comment.