diff --git a/.env b/.env index 70bf1aa..4b631a7 100644 --- a/.env +++ b/.env @@ -1,5 +1,14 @@ -PRIVATE_KEY = '' +PRIVATE_KEY = ' + + + + + + + +' +#Specify your instant RPC-node RPC_PROVIDER='https://ethereum-goerli.publicnode.com' -CHAIN_ID = 5 +CHAIN_ID = 5 #Specify chain_id for deploy contracts #FAUCETS: https://faucetlink.to/ diff --git a/README.md b/README.md index 544f0da..86d8c60 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ -[![Go version][go-badge]][go-url] [![go-report][go-report-badge]][go-report-url] [![Lint][lint-badge]][lint-url] [![Test][test-badge]][test-url] [![Build][build-badge]][build-url] [![Makefile][makefile-badge]][makefile-url] [![deploy][deploy-badge]][deploy-url] [![HitCount](https://hits.dwyl.com/whonion//SmartContractBatchDeployer.svg)](https://hits.dwyl.com/whonion/SmartContractBatchDeployer)[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fwhonion%2Fgo-solc-batch-deployer.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2Fwhonion%2Fgo-solc-batch-deployer?ref=badge_shield) +[![Status](https://img.shields.io/badge/status-active-success.svg)](https://github.com/whonion/go-solc-batch-deployer/blob/main/) [![Go version][go-badge]][go-url] [![go-report][go-report-badge]][go-report-url] [![Lint][lint-badge]][lint-url] [![Test][test-badge]][test-url] [![Build][build-badge]][build-url] [![Makefile][makefile-badge]][makefile-url] [![deploy][deploy-badge]][deploy-url] [![HitCount](https://hits.dwyl.com/whonion/go-solc-batch-deployer.svg)](https://hits.dwyl.com/whonion/go-solc-batch-deployer)[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fwhonion%2Fgo-solc-batch-deployer.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2Fwhonion%2Fgo-solc-batch-deployer?ref=badge_shield)
-# Example of batch deployment smart contracts to EVM using Go Lang
+## Example of batch deployment smart contracts to EVM using Go Lang
Implementation with go-ethereum
@@ -55,19 +55,27 @@ cd go-solc-batch-deployer - - Add to `.env-file` your variables: `PRIVATE_KEY` (without **0x**),`RPC_PROVIDER` and `CHAIN_ID` + - Add to `.env-file` your variables: `PRIVATE_KEY` (without **0x**), `RPC_PROVIDER` and `CHAIN_ID` ```sh +PRIVATE_KEY = ' + + + + + + + +' CHAIN_ID = 10 -PRIVATE_KEY = '0x.......................................................' -RPC_PROVIDER='https://rpc.ankr.com/optimism/{YOUR_API_KEY}' +RPC_PROVIDER = 'https://rpc.ankr.com/optimism/{YOUR_API_KEY}' ``` - Add correct files *.sol to the `contacts` folder for deployment on the required chain - Create new session with `tmux` ```sh -tmux new -s contract_deploy \ +tmux new -s contractdeploy \ ``` - Run `main.go` diff --git a/main.go b/main.go index 71799f5..30bf575 100644 --- a/main.go +++ b/main.go @@ -143,13 +143,13 @@ func main() { 534351: { ChainID: 534351, ChainName: "Scroll Alpha Testnet", - ExplorerURL: "https://sepolia-blockscout.scroll.io/", + ExplorerURL: "https://sepolia-blockscout.scroll.io", RPCURL: "https://1rpc.io/scroll/sepolia", }, 534352: { - ChainID: 534351, + ChainID: 534352, ChainName: "Scroll Mainnet", - ExplorerURL: "https://scrollscan.com/", + ExplorerURL: "https://scrollscan.com", RPCURL: "https://rpc.scroll.io", }, 59140: { @@ -161,7 +161,7 @@ func main() { 59144: { ChainID: 59144, ChainName: "Linea Mainnet", - ExplorerURL: "https://lineascan.build/", + ExplorerURL: "https://lineascan.build", RPCURL: "https://rpc.linea.build", }, 6102: { @@ -173,7 +173,7 @@ func main() { 34443: { ChainID: 34443, ChainName: "Mode network", - ExplorerURL: "https://explorer.mode.network/", + ExplorerURL: "https://explorer.mode.network", RPCURL: "https://1rpc.io/mode", }, 7000: { @@ -182,6 +182,18 @@ func main() { ExplorerURL: "https://explorer.zetachain.com", RPCURL: "https://zeta.rpcgrid.com", }, + 8453: { + ChainID: 8453, + ChainName: "Base Mainnet", + ExplorerURL: "https://basescan.org", + RPCURL: "https://base-rpc.publicnode.com", + }, + 204: { + ChainID: 204, + ChainName: "opBNB", + ExplorerURL: "https://mainnet.opbnbscan.com", + RPCURL: "https://opbnb-rpc.publicnode.com", + }, } for _, privateKeyStr := range privateKeys { privateKey, err := crypto.HexToECDSA(strings.TrimSpace(privateKeyStr))