-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjustfile
More file actions
65 lines (46 loc) · 1.68 KB
/
justfile
File metadata and controls
65 lines (46 loc) · 1.68 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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# PoRep Market task runner
# Run `just` to see all available commands
set dotenv-load
fmt:
forge fmt
fmt-check:
forge fmt --check
lint:
solhint 'src/**/*.sol' 'test/**/*.sol' 'script/**/*.sol' --max-warnings 0
test:
forge test -vvv
build:
forge build --build-info --sizes
clean:
forge clean
gen-abis:
forge build
for f in $(find src -name '*.sol' ! -path "*/interfaces/*" ! -path "*/types/*" ! -path "*/libs/*"); do \
name="$(basename "${f%.sol}")"; \
jq .abi "out/$(basename "$f")/$name.json" > "abis/$name.json"; \
done
check-abis:
./ci/check-abis.sh
coverage:
./coverage.sh
check-coverage:
./ci/check-full-coverage.sh
deploy flags='':
forge script script/Deploy.s.sol:Deploy --gas-estimate-multiplier 100000 --disable-block-gas-limit -vvvv --broadcast --rpc-url $RPC_URL --private-key $PRIVATE_KEY {{flags}}
upgrade flags='':
forge script script/Upgrade.s.sol:Upgrade --gas-estimate-multiplier 100000 --disable-block-gas-limit -vvvv --broadcast --rpc-url $RPC_URL --private-key $PRIVATE_KEY {{flags}}
devnet_deploy: clean build
RPC_URL=$RPC_TEST PRIVATE_KEY=$PRIVATE_KEY_TEST just deploy
calibnet_deploy: clean build
RPC_URL=$RPC_CALIBNET PRIVATE_KEY=$PRIVATE_KEY_CALIBNET just deploy --slow
devnet_upgrade: clean build
RPC_URL=$RPC_TEST PRIVATE_KEY=$PRIVATE_KEY_TEST just upgrade
calibnet_upgrade: clean build
RPC_URL=$RPC_CALIBNET PRIVATE_KEY=$PRIVATE_KEY_CALIBNET just upgrade --slow
# CI equivalent check
check: fmt-check lint test check-coverage build check-abis
@echo "All checks passed."
pre-push: fmt-check lint test check-abis
@echo "Ready to push."
fix: fmt lint test
@echo "Fixed and validated."