2024-03-23 15:11:56 -05:00
|
|
|
const { ethers, run } = require('hardhat');
|
|
|
|
|
|
|
|
const contractAddresses = require('../contract-addresses.json');
|
|
|
|
|
|
|
|
require('dotenv').config();
|
|
|
|
|
|
|
|
const network = process.env.HARDHAT_NETWORK;
|
|
|
|
const work1Price = ethers.parseEther(process.env.WORK1_PRICE || 0.001);
|
|
|
|
const onboardingPrice = ethers.parseEther(process.env.ONBOARDING_PRICE || '0.001');
|
|
|
|
|
|
|
|
async function main() {
|
|
|
|
// Unless deploying locally, run the verify task
|
|
|
|
if (network !== 'localhost') {
|
|
|
|
await run('verify:verify', {
|
|
|
|
address: contractAddresses[network].DAO,
|
|
|
|
});
|
|
|
|
|
|
|
|
await run('verify:verify', {
|
2024-04-02 14:04:55 -05:00
|
|
|
address: contractAddresses[network].Proposals,
|
2024-03-23 15:11:56 -05:00
|
|
|
constructorArguments: [
|
|
|
|
contractAddresses[network].DAO,
|
|
|
|
],
|
|
|
|
});
|
|
|
|
|
|
|
|
await run('verify:verify', {
|
2024-04-02 14:04:55 -05:00
|
|
|
address: contractAddresses[network].Work1,
|
2024-03-23 15:11:56 -05:00
|
|
|
constructorArguments: [
|
|
|
|
contractAddresses[network].DAO,
|
2024-04-02 14:04:55 -05:00
|
|
|
contractAddresses[network].Proposals,
|
|
|
|
work1Price,
|
2024-03-23 15:11:56 -05:00
|
|
|
],
|
|
|
|
});
|
2024-03-29 10:59:29 -05:00
|
|
|
|
|
|
|
await run('verify:verify', {
|
2024-04-02 14:04:55 -05:00
|
|
|
address: contractAddresses[network].Onboarding,
|
2024-03-29 10:59:29 -05:00
|
|
|
constructorArguments: [
|
|
|
|
contractAddresses[network].DAO,
|
2024-04-02 14:04:55 -05:00
|
|
|
contractAddresses[network].Proposals,
|
|
|
|
onboardingPrice,
|
2024-03-29 10:59:29 -05:00
|
|
|
],
|
|
|
|
});
|
2024-03-23 15:11:56 -05:00
|
|
|
}
|
|
|
|
}
|
|
|
|
// We recommend this pattern to be able to use async/await everywhere
|
|
|
|
// and properly handle errors.
|
|
|
|
main().catch((error) => {
|
|
|
|
console.error(error);
|
|
|
|
process.exitCode = 1;
|
|
|
|
});
|