feat: add deploy script & makefile

This commit is contained in:
snsd0805 2024-04-27 03:30:33 +08:00
parent 00a08d9f78
commit a6db247d35
Signed by: snsd0805
GPG Key ID: 569349933C77A854
2 changed files with 18 additions and 0 deletions

11
Makefile Normal file
View File

@ -0,0 +1,11 @@
all: out/Scheduler.sol abi/Scheduler.abi
out/Scheduler.sol: src/Scheduler.sol
forge build
solc --abi src/Scheduler.sol -o abi
clean:
rm -rf out/Scheduler.sol abi/Scheduler.abi
deploy: out/Scheduler.sol
forge create --rpc-url=$(LOCALHOST) --private-key=$(OWNER_KEY) Scheduler

7
deploy.sh Executable file
View File

@ -0,0 +1,7 @@
export LOCALHOST="http://localhost:8545"
export OWNER_KEY="0x5de4111afa1a4b94908f83103eb1f1706367c2e68ca870fc3fb9a804cdab365a"
export PROVIDER_KEY="0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80"
export CLIENT_KEY="0x59c6995e998f97a5a0044966f0945389dc9e86dae88c7a8412f4603b6b78690d"
make clean
make
make deploy