-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdeploy.sh
executable file
·36 lines (31 loc) · 1.15 KB
/
deploy.sh
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
#!/bin/bash
# Check if an argument is provided
if [ -z "$1" ]; then
echo "Usage: $0 {deploy|update|role}"
exit 1
fi
# Set the script path based on the argument
case "$1" in
deploy)
SCRIPT_PATH="Deploy.s.sol"
;;
update)
SCRIPT_PATH="Update.s.sol"
;;
role)
SCRIPT_PATH="GrantRoles.s.sol"
;;
*)
echo "Invalid argument: $1"
echo "Usage: $0 {deploy|update|role}"
exit 1
;;
esac
source .env
export FORCE_DEPLOY="false"
# echo "Deploying contracts to arbitrum testnet"
forge script script/$SCRIPT_PATH --rpc-url $ARBITRUM_SEPOLIA_RPC_URL --account mainnettDeployer --sender 0xaE4e57b886541829BA70eFC84340653c41e2908C --broadcast --verify
# forge script script/$SCRIPT_PATH --rpc-url $ARBITRUM_SEPOLIA_RPC_URL --account mainnettDeployer --sender 0xaE4e57b886541829BA70eFC84340653c41e2908C
# echo "Deploying contracts to arbitrum"
forge script script/$SCRIPT_PATH --rpc-url $ARBITRUM_RPC_URL --account mainnettDeployer --sender 0xaE4e57b886541829BA70eFC84340653c41e2908C --broadcast --verify
# forge script script/$SCRIPT_PATH --rpc-url $ARBITRUM_RPC_URL --account mainnettDeployer --sender 0xaE4e57b886541829BA70eFC84340653c41e2908C