From 388c424a1ef9601b73ac3d960e54fcaedc0950c3 Mon Sep 17 00:00:00 2001 From: Adarsh Ravichandran Date: Wed, 14 Aug 2024 16:59:38 +0530 Subject: [PATCH] chore(eth-multisig-v4): add bera config Ticket: WIN-3295 --- .github/workflows/deploy_and_release.yml | 14 ++++++++++++++ .github/workflows/push.yml | 1 + hardhat.config.ts | 20 ++++++++++++++++++-- scripts/deploy.ts | 5 +++++ 4 files changed, 38 insertions(+), 2 deletions(-) diff --git a/.github/workflows/deploy_and_release.yml b/.github/workflows/deploy_and_release.yml index 0896234..59568eb 100644 --- a/.github/workflows/deploy_and_release.yml +++ b/.github/workflows/deploy_and_release.yml @@ -36,6 +36,7 @@ jobs: OPTIMISTIC_ETHERSCAN_API_KEY: ${{ secrets.OPTIMISTIC_ETHERSCAN_API_KEY }} ZKSYNC_EXPLORER_API_KEY: ${{ secrets.ZKSYNC_EXPLORER_API_KEY }} BASESCAN_API_KEY: ${{ secrets.BASESCAN_API_KEY }} + BARTIO_BERA_EXPLORER_API_KEY: ${{ secrets.BARTIO_BERA_EXPLORER_API_KEY }} get-network: runs-on: ubuntu-latest needs: [lint-and-test] @@ -56,7 +57,11 @@ jobs: deploy-to-test: runs-on: ubuntu-latest needs: [lint-and-test, get-network] +<<<<<<< HEAD if: ${{ (needs.get-network.outputs.network == 'hteth' ) || (needs.get-network.outputs.network == 'tmatic' ) || (needs.get-network.outputs.network == 'tbsc' ) || (needs.get-network.outputs.network == 'tarbeth' ) || (needs.get-network.outputs.network == 'topeth' ) || (needs.get-network.outputs.network == 'tzketh' ) || (needs.get-network.outputs.network == 'tbaseeth' )}} +======= + if: ${{ (needs.get-network.outputs.network == 'hteth' ) || (needs.get-network.outputs.network == 'tmatic' ) || (needs.get-network.outputs.network == 'tbsc' ) || (needs.get-network.outputs.network == 'tarbeth' ) || (needs.get-network.outputs.network == 'topeth' ) || (needs.get-network.outputs.network == 'tzketh' ) || (needs.get-network.outputs.network == 'tbera' ) }} +>>>>>>> 5b256f8 (chore(eth-multisig-v4): add bera config) environment: testnet steps: - uses: actions/checkout@v2 @@ -84,7 +89,11 @@ jobs: ARBISCAN_API_KEY: ${{ secrets.ARBISCAN_API_KEY }} OPTIMISTIC_ETHERSCAN_API_KEY: ${{ secrets.OPTIMISTIC_ETHERSCAN_API_KEY }} ZKSYNC_EXPLORER_API_KEY: ${{ secrets.ZKSYNC_EXPLORER_API_KEY }} +<<<<<<< HEAD BASESCAN_API_KEY: ${{ secrets.BASESCAN_API_KEY }} +======= + BARTIO_BERA_EXPLORER_API_KEY: ${{ secrets.BARTIO_BERA_EXPLORER_API_KEY }} +>>>>>>> 5b256f8 (chore(eth-multisig-v4): add bera config) - name: Update release notes uses: actions/github-script@v6 with: @@ -116,7 +125,11 @@ jobs: deploy-to-prod: runs-on: ubuntu-latest needs: [lint-and-test, get-network] +<<<<<<< HEAD if: ${{ (needs.get-network.outputs.network == 'eth' ) || (needs.get-network.outputs.network == 'matic' ) || (needs.get-network.outputs.network == 'bsc' ) || (needs.get-network.outputs.network == 'arbeth' ) || (needs.get-network.outputs.network == 'opeth' ) || (needs.get-network.outputs.network == 'zketh' ) || (needs.get-network.outputs.network == 'baseeth' )}} +======= + if: ${{ (needs.get-network.outputs.network == 'eth' ) || (needs.get-network.outputs.network == 'matic' ) || (needs.get-network.outputs.network == 'bsc' ) || (needs.get-network.outputs.network == 'arbeth' ) || (needs.get-network.outputs.network == 'opeth' ) || (needs.get-network.outputs.network == 'zketh' ) || (needs.get-network.outputs.network == 'bera' )}} +>>>>>>> 5b256f8 (chore(eth-multisig-v4): add bera config) environment: mainnet steps: - uses: actions/checkout@v2 @@ -141,6 +154,7 @@ jobs: ARBISCAN_API_KEY: ${{ secrets.ARBISCAN_API_KEY }} OPTIMISTIC_ETHERSCAN_API_KEY: ${{ secrets.OPTIMISTIC_ETHERSCAN_API_KEY }} ZKSYNC_EXPLORER_API_KEY: ${{ secrets.ZKSYNC_EXPLORER_API_KEY }} + BARTIO_BERA_EXPLORER_API_KEY: ${{ secrets.BARTIO_BERA_EXPLORER_API_KEY }} QUICKNODE_ARBITRUM_ONE_API_KEY: ${{ secrets.QUICKNODE_ARBITRUM_ONE_API_KEY }} QUICKNODE_OPTIMISM_API_KEY: ${{ secrets.QUICKNODE_OPTIMISM_API_KEY }} BASESCAN_API_KEY: ${{ secrets.BASESCAN_API_KEY }} diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index fb25cd5..ce9c345 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -44,4 +44,5 @@ jobs: OPTIMISTIC_ETHERSCAN_API_KEY: ${{ secrets.OPTIMISTIC_ETHERSCAN_API_KEY }} ZKSYNC_EXPLORER_API_KEY: ${{ secrets.ZKSYNC_EXPLORER_API_KEY }} BASESCAN_API_KEY: ${{ secrets.BASESCAN_API_KEY }} + BARTIO_BERA_EXPLORER_API_KEY: ${{ secrets.BARTIO_BERA_EXPLORER_API_KEY }} - run: npm run lint diff --git a/hardhat.config.ts b/hardhat.config.ts index fba805c..fb4c4d2 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -28,7 +28,8 @@ const { ARBISCAN_API_KEY, OPTIMISTIC_ETHERSCAN_API_KEY, ZKSYNC_EXPLORER_API_KEY, - BASESCAN_API_KEY + BASESCAN_API_KEY, + BARTIO_BERA_EXPLORER_API_KEY } = process.env; const config: HardhatUserConfig = { @@ -130,6 +131,10 @@ const config: HardhatUserConfig = { baseeth: { url: 'https://mainnet.base.org/', accounts: [`${MAINNET_PRIVATE_KEY_FOR_CONTRACT_DEPLOYMENT}`] + }, + tbera: { + url: `https://bartio.rpc.berachain.com/`, + accounts: [`${PRIVATE_KEY_FOR_V4_CONTRACT_DEPLOYMENT}`] } }, gasReporter: { @@ -158,7 +163,9 @@ const config: HardhatUserConfig = { zksyncSepolia: `${ZKSYNC_EXPLORER_API_KEY}`, // base chain baseSepolia: `${BASESCAN_API_KEY}`, - base: `${BASESCAN_API_KEY}` + base: `${BASESCAN_API_KEY}`, + // bera + bartioBera: `${BARTIO_BERA_EXPLORER_API_KEY}` }, customChains: [ { @@ -201,6 +208,15 @@ const config: HardhatUserConfig = { browserURL: 'https://sepolia.explorer.zksync.io' } }, + { + network: 'bartioBera', + chainId: 80084, + urls: { + apiURL: + 'https://api.routescan.io/v2/network/testnet/evm/80084/etherscan/api', + browserURL: 'https://bartio.beratrail.io' + } + }, { network: 'polygonAmoy', chainId: 80002, diff --git a/scripts/deploy.ts b/scripts/deploy.ts index 5693c8f..695ad97 100644 --- a/scripts/deploy.ts +++ b/scripts/deploy.ts @@ -87,6 +87,11 @@ async function main() { forwarderContractName = 'Forwarder'; forwarderFactoryContractName = 'ForwarderFactory'; contractPath = `contracts/${walletImplementationContractName}.sol:${walletImplementationContractName}`; + case 80084: + walletImplementationContractName = 'WalletSimple'; + forwarderContractName = 'ForwarderV4'; + forwarderFactoryContractName = 'ForwarderFactoryV4'; + contractPath = `contracts/${walletImplementationContractName}.sol:${walletImplementationContractName}`; break; }