Skip to content

Commit

Permalink
Document all smart contract msg + queries with secretcli
Browse files Browse the repository at this point in the history
  • Loading branch information
itsHaseebSaeed committed Dec 24, 2023
1 parent 7b9c85b commit 920667b
Show file tree
Hide file tree
Showing 17 changed files with 4,666 additions and 91 deletions.
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
use std::str::FromStr;

use ethnum::U256;
use shade_protocol::{
c_std::{to_binary, Addr, ContractInfo, Uint128, Uint256},
lb_libraries::types::{
ContractInstantiationInfo,
LBPair,
LBPairInformation,
StaticFeeParameters,
lb_libraries::{
math::uint256_to_u256::ConvertU256,
types::{ContractInstantiationInfo, LBPair, LBPairInformation, StaticFeeParameters},
},
liquidity_book::lb_pair::{LiquidityParameters, RemoveLiquidity},
liquidity_book::lb_pair::{LiquidityParameters, RemoveLiquidity, RewardsDistribution},
snip20::Snip20ReceiveMsg,
swap::core::{TokenAmount, TokenType},
utils::asset::RawContract,
Expand Down
13 changes: 0 additions & 13 deletions contracts/liquidity_book/lb_factory/src/bin/secretcli/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,19 +41,6 @@ macro_rules! print_execute_messages {
};
}

macro_rules! print_query_messages {
($file:ident, $($var:ident),+ $(,)?) => {
$(
writeln!($file,
"### {}\n\n```sh\nsecretcli query compute query secret1foobar '{}'\n```",
stringify!($var),
serde_json::to_string_pretty(&$var).unwrap()
)?;
writeln!($file, "\n")?;
)+
};
}

macro_rules! print_query_messages_with_responses {
($file:ident, $(($cmd:ident, $resp:ident)),+ $(,)?) => {
$(
Expand Down
1 change: 1 addition & 0 deletions contracts/liquidity_book/lb_pair/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ serde-json-wasm = { version = "1.0"}
cosmwasm-schema = "1.5"
thiserror = { version = "1.0" }
ethnum = { version = "1.5" }
serde_json = "1"

[dev-dependencies]
anyhow = "1"
Expand Down
Loading

0 comments on commit 920667b

Please sign in to comment.