Commit 780fc0f5 authored by Mark Tyneway's avatar Mark Tyneway

deployments: fix merge conflict

parent 9469e611
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
import { DeployFunction } from 'hardhat-deploy/dist/types'
import { deploy } from '../src/deploy-utils'
const deployFn: DeployFunction = async (hre) => {
// We only want to deploy the dgf on devnet for now
if (hre.deployConfig.l1ChainID === 900) {
const disputeGameFactory = await deploy({
hre,
name: 'DisputeGameFactory',
args: [],
})
console.log('DisputeGameFactory deployed at ' + disputeGameFactory.address)
}
}
deployFn.tags = ['DisputeGameFactoryImpl', 'setup', 'l1']
const network = await hre.ethers.provider.getNetwork()
const chainId = network.chainId
export default deployFn
||||||| parent of b998a6a67 (DisputeGameFactory devnet deploy scripts)
=======
import assert from 'assert'
||||||| parent of 4c1b5e2ac (Remove final owner from dgf impl initialization.)
import assert from 'assert'
=======
>>>>>>> 4c1b5e2ac (Remove final owner from dgf impl initialization.)
import { DeployFunction } from 'hardhat-deploy/dist/types'
import { deploy } from '../src/deploy-utils'
const deployFn: DeployFunction = async (hre) => {
// We only want to deploy the dgf on devnet for now
if (hre.deployConfig.l1ChainID === 900) {
if (chainId === 900) {
const disputeGameFactory = await deploy({
hre,
name: 'DisputeGameFactory',
args: [],
})
console.log('DisputeGameFactory deployed at ' + disputeGameFactory.address)
}
}
deployFn.tags = ['DisputeGameFactoryImpl', 'setup', 'l1']
export default deployFn
>>>>>>> b998a6a67 (DisputeGameFactory devnet deploy scripts)
||||||| parent of f8dc1be47 (DisputeGameFactory devnet deploy scripts)
=======
import assert from 'assert'
import { DeployFunction } from 'hardhat-deploy/dist/types'
import { deploy } from '../src/deploy-utils'
const deployFn: DeployFunction = async (hre) => {
// We only want to deploy the dgf on devnet for now
if (hre.deployConfig.l1ChainID === 900) {
const finalOwner = hre.deployConfig.finalSystemOwner
const disputeGameFactory = await deploy({
hre,
name: 'DisputeGameFactory',
args: [finalOwner],
})
const fetchedOwner = await disputeGameFactory.owner()
assert(fetchedOwner === finalOwner)
console.log('DisputeGameFactory deployed at ' + disputeGameFactory.address)
console.log(`DisputeGameFactory deployed at ${disputeGameFactory.address}`)
} else {
console.log('Skipping deployment of DisputeGameFactory implementation')
}
}
deployFn.tags = ['DisputeGameFactoryImpl', 'setup', 'l1']
export default deployFn
>>>>>>> f8dc1be47 (DisputeGameFactory devnet deploy scripts)
......@@ -7,8 +7,12 @@ import 'hardhat-deploy'
import { getContractsFromArtifacts } from '../src/deploy-utils'
const deployFn: DeployFunction = async (hre) => {
// We only want to deploy the dgf on devnet for now
const network = await hre.ethers.provider.getNetwork()
const chainId = network.chainId
// The DisputeGameFactory is only deployed on devnet
if (hre.deployConfig.l1ChainID === 900) {
if (chainId === 900) {
const { deployer } = await hre.getNamedAccounts()
const [proxyAdmin, disputeGameFactoryProxy, disputeGameFactoryImpl] =
await getContractsFromArtifacts(hre, [
......@@ -45,6 +49,8 @@ const deployFn: DeployFunction = async (hre) => {
assert(fetchedOwner === finalOwner)
console.log('Updgraded and initialized DisputeGameFactory')
} else {
console.log('Skipping initialization of DisputeGameFactory')
}
}
......
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