Commit 6014ec06 authored by Mark Tyneway's avatar Mark Tyneway Committed by GitHub

contracts: add sequencer and deployer to addresses.json (#580)

* contracts: add sequencer and deployer to addresses.json

* chore: add changeset
parent 5f376ee5
---
"@eth-optimism/contracts": patch
---
Adds OVM_Sequencer and Deployer to the addresses.json output file
......@@ -17,9 +17,10 @@ process.env.CONTRACTS_RPC_URL =
import hre from 'hardhat'
const sequencer = new Wallet(process.env.SEQUENCER_PRIVATE_KEY)
const deployer = new Wallet(process.env.DEPLOYER_PRIVATE_KEY)
const main = async () => {
const sequencer = new Wallet(process.env.SEQUENCER_PRIVATE_KEY)
const deployer = new Wallet(process.env.DEPLOYER_PRIVATE_KEY)
const config = parseEnv()
......@@ -49,7 +50,7 @@ const main = async () => {
'mockOVM_BondManager': 'OVM_BondManager'
}
const contracts = dirtree(
const contracts: any = dirtree(
path.resolve(__dirname, `../deployments/custom`)
).children.filter((child) => {
return child.extension === '.json'
......@@ -60,6 +61,9 @@ const main = async () => {
return contracts
}, {})
contracts.OVM_Sequencer = await sequencer.getAddress()
contracts.Deployer = await deployer.getAddress()
const addresses = JSON.stringify(contracts, null, 2)
const dumpsPath = path.resolve(__dirname, "../dist/dumps")
if (!fs.existsSync(dumpsPath)) {
......@@ -100,4 +104,3 @@ function parseEnv() {
sccSequencerPublishWindow: ensure('SEQUENCER_PUBLISH_WINDOW_SECONDS', 'number'),
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment