-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
28 lines (22 loc) · 720 Bytes
/
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
prepare:
rustup target add wasm32-unknown-unknown
build-contract:
cd contract && cargo build --release --target wasm32-unknown-unknown
wasm-strip contract/target/wasm32-unknown-unknown/release/contract.wasm 2>/dev/null | true
test: build-contract
mkdir -p tests/wasm
cp target/wasm32-unknown-unknown/release/contract.wasm tests/wasm
cd tests && cargo test
clippy:
cd contract && cargo clippy --all-targets -- -D warnings
cd tests && cargo clippy --all-targets -- -D warnings
check-lint: clippy
cd contract && cargo fmt -- --check
cd tests && cargo fmt -- --check
lint: clippy
cd contract && cargo fmt
cd tests && cargo fmt
clean:
cd contract && cargo clean
cd tests && cargo clean
rm -rf tests/wasm