Skip to content

Commit

Permalink
Update deploy script
Browse files Browse the repository at this point in the history
  • Loading branch information
AbdeltwabMF committed Jul 8, 2022
1 parent 7beab00 commit a30fc06
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion pages/_app.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export default function App ({ Component, pageProps }) {
const [blockNumber, setBlockNumber] = useState(UNSET)
const [balance, setBalance] = useState(UNSET)
// 3 = '0x449fE6C97F4AD1d4769971F9fb1C33a64856AB73'
const contractAddress = '0x449fE6C97F4AD1d4769971F9fb1C33a64856AB73'
const contractAddress = '0x801e446103561Ac3d0eb8fC416a44917FC83a4D5'

useEffect(() => {
import('bootstrap/dist/js/bootstrap.min.js')
Expand Down
7 changes: 7 additions & 0 deletions scripts/deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,13 @@ main() {
if [[ "$network" != "localhost" ]]; then
if (( $2 == 1 )); then
deploy_to_network
while [[ $smart_contract_address == "" ]]; do
error "Unable to deploy the smart contracts to $network network"
warn "Please check your node is up and running and try again"
info "Retrying in 5 seconds..."
sleep 5s
deploy_to_network
done
info "A new smart contract address: $(decorize_address) is cached"
sed -i "s/SMART_CONTRACT_ADDRESS_ROPSTEN.*$/SMART_CONTRACT_ADDRESS_ROPSTEN=$smart_contract_address/" ./.env
else
Expand Down

0 comments on commit a30fc06

Please sign in to comment.