-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
47 lines (36 loc) · 1.81 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
build:
cargo wasm
optimize:
docker run --rm -v "$$(pwd)":/code \
--mount type=volume,source="$$(basename "$$(pwd)")_cache",target=/code/target \
--mount type=volume,source=registry_cache,target=/usr/local/cargo/registry \
cosmwasm/rust-optimizer:0.14.0
test:
cargo unit-test
WALLET=nibi1uds8m92jzp465px8xjmuj4jmhcd5h2wsh404cl
AIRDROP_CONTRACT=nibi1hc3cl36mnty08e34cp6gy4rnej378w7qhrxjxxzq3jdm04qa5w5seqwemv
CODE_ID=436
WALLET_NAME=jarvis
make-wallet:
@nibid keys add ${WALLET_NAME}
show-wallet:
@nibid keys show -a ${WALLET}
get-balance:
@nibid query bank balances ${WALLET} --denom unibi
upload-testnet:
@nibid tx wasm store artifacts/jarvis_airdrop.wasm --from ${WALLET} --gas auto --gas-adjustment 1.5 --gas-prices 0.025unibi --yes
instantiate-testnet:
$(eval INSTANTIATE := $$(shell cat ./commands/instantiate.json))
@nibid tx wasm instantiate ${CODE_ID} '${INSTANTIATE}' --admin ${WALLET} --label airdrop --from ${WALLET} --gas auto --gas-adjustment 1.5 --gas-prices 0.025unibi --yes
get-nft-contract-address:
$(eval GET_NFT_CONTRACT_ADDRESS := $$(shell cat ./commands/get_nft_contract_addr.json))
@nibid query wasm contract-state smart ${AIRDROP_CONTRACT} '$(GET_NFT_CONTRACT_ADDRESS)'
get-all-nfts:
$(eval GET_ALL_NFTS := $$(shell cat ./commands/get_all_nfts.json))
@nibid query wasm contract-state smart ${AIRDROP_CONTRACT} '$(GET_ALL_NFTS)'
exe-set-nft-contract-addr:
$(eval SET_NFT_CONTRACT_ADDR := $$(shell cat ./commands/set_nft_contract_addr.json))
@nibid tx wasm execute ${AIRDROP_CONTRACT} '$(SET_NFT_CONTRACT_ADDR)' --from ${WALLET} --gas auto --gas-adjustment 1.5 --gas-prices 0.025unibi --yes
exe-send-nfts:
$(eval SEND_NFTS := $$(shell cat ./commands/send_nfts.json))
@nibid tx wasm execute ${AIRDROP_CONTRACT} '$(SEND_NFTS)' --from ${WALLET} --gas auto --gas-adjustment 1.5 --gas-prices 0.025unibi --yes