-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
44 lines (34 loc) · 1.02 KB
/
Makefile
File metadata and controls
44 lines (34 loc) · 1.02 KB
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
.PHONY: build test lint format clean deploy idl devnet help
PROGRAM_ID := 4bUHrDPuRcoYPU7UTLojXtxJsWoCj3HJbKX9oLnEnYy6
CLUSTER := devnet
help:
@echo "KIRITE Protocol — make targets"
@echo " build - anchor build (compile on-chain program)"
@echo " test - cargo test + sdk tests"
@echo " lint - cargo clippy + sdk lint"
@echo " format - cargo fmt + prettier"
@echo " idl - regenerate IDL JSON"
@echo " devnet - run devnet integration test"
@echo " deploy - deploy program to $(CLUSTER)"
@echo " clean - remove build artifacts"
build:
anchor build
test:
cargo test --all
cd sdk && npm test
lint:
cargo clippy --all-targets --all-features -- -D warnings
cd sdk && npm run lint
format:
cargo fmt --all
cd sdk && npx prettier --write .
idl:
anchor build
cp target/idl/kirite.json programs/kirite/idl/kirite.json
devnet:
npx tsx tests/test-devnet-e2e.ts
deploy:
solana program deploy target/deploy/kirite.so --url $(CLUSTER)
clean:
cargo clean
rm -rf .anchor sdk/node_modules sdk/dist