diff --git a/hardhat.config.ts b/hardhat.config.ts index 17f2358f1..207c5bfde 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -195,6 +195,17 @@ const config: HardhatUserConfig = { count: 20, }, }, + holesky: { + url: process.env.HOLESKY_PROVIDER + ? process.env.HOLESKY_PROVIDER + : `https://holesky.infura.io/v3/${process.env.INFURA_PROJECT_ID}`, + accounts: { + mnemonic: process.env.MNEMONIC || DEFAULT_MNEMONIC, + path: "m/44'/60'/0'/0", + initialIndex: 0, + count: 20, + }, + }, localhost: { url: "http://127.0.0.1:8545", accounts: { @@ -254,6 +265,7 @@ const config: HardhatUserConfig = { polygonZKEVMMainnet: `${process.env.ETHERSCAN_ZKEVM_API_KEY}`, goerli: `${process.env.ETHERSCAN_API_KEY}`, sepolia: `${process.env.ETHERSCAN_API_KEY}`, + holesky: `${process.env.ETHERSCAN_API_KEY}`, mainnet: `${process.env.ETHERSCAN_API_KEY}`, zkevmDevnet: `${process.env.ETHERSCAN_API_KEY}`, }, diff --git a/package.json b/package.json index bb019d823..20d017c2f 100644 --- a/package.json +++ b/package.json @@ -109,6 +109,15 @@ "upgradev2L2:timelock:polygonZKEVMMainnet": "npx hardhat run upgrade/upgradeToV2/upgradeL2ToV2.ts --network polygonZKEVMMainnet", "upgradev2:timelock:mainnet": "npx hardhat run upgrade/upgradeToV2/upgradeToV2.ts --network mainnet && npm run saveUpgradeV2:mainnet", "verify:upgradeV2:mainnet": "npx hardhat run upgrade/upgradeToV2/verifyContracts.ts --network mainnet", - "saveUpgradeV2:mainnet": "mkdir -p upgrade/upgradeToV2/mainnet_$(date +%s) && cp -r upgrade/upgradeToV2/upgrade_*.json upgrade/upgradeToV2/mainnet_$(date +%s) && cp -r upgrade/upgradeToV2/deploy_*.json upgrade/upgradeToV2/mainnet_$(date +%s) && cp .openzeppelin/mainnet.json upgrade/upgradeToV2/mainnet_$(date +%s)" + "saveUpgradeV2:mainnet": "mkdir -p upgrade/upgradeToV2/mainnet_$(date +%s) && cp -r upgrade/upgradeToV2/upgrade_*.json upgrade/upgradeToV2/mainnet_$(date +%s) && cp -r upgrade/upgradeToV2/deploy_*.json upgrade/upgradeToV2/mainnet_$(date +%s) && cp .openzeppelin/mainnet.json upgrade/upgradeToV2/mainnet_$(date +%s)", + "prepare:testnet:ZkEVM:holesky": "npx hardhat run deployment/testnet/prepareTestnet.ts --network holesky", + "deploy:v2:holesky": "npx hardhat compile && npx ts-node deployment/v2/1_createGenesis.ts && npx hardhat run deployment/v2/2_deployPolygonZKEVMDeployer.ts --network holesky && npx hardhat run deployment/v2/3_deployContracts.ts --network holesky && npx hardhat run deployment/v2/4_createRollup.ts --network holesky && npm run saveDeployment:holesky", + "deploy:testnet:v2:holesky": "npx hardhat compile && rm -f deployment/v2/deploy_ongoing.json && npm run prepare:testnet:ZkEVM:holesky && npm run deploy:v2:holesky", + "verify:v2:holesky": "npx hardhat run deployment/v2/verifyContracts.js --network holesky", + "saveDeployment:holesky": "mkdir -p deployments/holesky_$(date +%s) && cp -r deployment/v2/deploy_*.json deployments/holesky_$(date +%s) && cp .openzeppelin/holesky.json deployments/holesky_$(date +%s) && cp deployment/v2/genesis.json deployments/holesky_$(date +%s) && cp deployment/v2/create_rollup_output.json deployments/holesky_$(date +%s)", + "testnetPol:upgradeV2:holesky": "npx hardhat run upgrade/upgradeToV2/testnet/deployTestnetPol.ts --network holesky", + "upgradev2:timelock:holesky": "npx hardhat run upgrade/upgradeToV2/upgradeToV2.ts --network holesky && npm run saveUpgradeV2:holesky", + "verify:upgradeV2:holesky": "npx hardhat run upgrade/upgradeToV2/verifyContracts.ts --network holesky", + "saveUpgradeV2:holesky": "mkdir -p upgrade/upgradeToV2/holesky_$(date +%s) && cp -r upgrade/upgradeToV2/upgrade_*.json upgrade/upgradeToV2/holesky_$(date +%s) && cp -r upgrade/upgradeToV2/deploy_*.json upgrade/upgradeToV2/holesky_$(date +%s) && cp .openzeppelin/holesky.json upgrade/upgradeToV2/holesky_$(date +%s)" } } \ No newline at end of file