Compare commits

..

No commits in common. "ea9b28457c573757e64d84f40cfe05e97d890d13" and "e049d9b107ed0d99e990de0604a9f0c3bcc59c82" have entirely different histories.

2 changed files with 21 additions and 38 deletions

@ -23,15 +23,18 @@
"web3-utils": "^1.10.0" "web3-utils": "^1.10.0"
}, },
"devDependencies": { "devDependencies": {
<<<<<<< HEAD
"@nomiclabs/hardhat-ethers": "^2.2.3", "@nomiclabs/hardhat-ethers": "^2.2.3",
"@nomiclabs/hardhat-waffle": "^2.0.6", "@nomiclabs/hardhat-waffle": "^2.0.6",
"chai": "^4.3.7", "chai": "^4.3.7",
"ethereum-waffle": "^4.0.10", "ethereum-waffle": "^4.0.10",
"ethers": "^6.5.1", "ethers": "^6.5.1",
=======
"@nomicfoundation/hardhat-foundry": "^1.0.1", "@nomicfoundation/hardhat-foundry": "^1.0.1",
"@nomicfoundation/hardhat-verify": "^1.0.1", "@nomicfoundation/hardhat-verify": "^1.0.1",
"@nomiclabs/hardhat-ethers": "^2.2.3", "@nomiclabs/hardhat-ethers": "^2.2.3",
"ethers": "^5", "ethers": "^5",
>>>>>>> 80078475d5d09a2b730f8334120a524d069ec5b1
"hardhat": "^2.15.0", "hardhat": "^2.15.0",
"ts-node": "^10.9.1", "ts-node": "^10.9.1",
"typescript": "^5.1.3" "typescript": "^5.1.3"

@ -1,48 +1,28 @@
const hre = require("hardhat"); const hre = require('hardhat')
const config = require("../config"); const config = require("../config")
const { ethers } = hre; const { ethers } = hre
const sleep = (s) => new Promise((r) => setTimeout(r, s * 1000));
async function main() { async function main() {
const factory_staking = await ethers.getContractFactory( const factory_staking = await ethers.getContractFactory("TornadoStakingRewards")
"TornadoStakingRewards" const factory_proposal = await ethers.getContractFactory("Proposal")
);
const factory_proposal = await ethers.getContractFactory(
"RestoreRewardsProposal"
);
const staking = await factory_staking.deploy( const staking = await factory_staking.deploy(config.governanceProxy, config.torn, config.registryProxy)
config.governanceProxy,
config.torn,
config.registryProxy
);
await sleep(20);
console.log( console.log("\nStaking contract impl successfully deployed @ " + staking.address + '\n')
"\nStaking contract impl successfully deployed @ " + staking.target + "\n"
);
await hre.run("verify:verify", { await hre.run('verify:verify', {
address: staking.target, address: staking.address,
constructorArguments: [ constructorArguments: [config.governanceProxy, config.torn, config.registryProxy],
config.governanceProxy, })
config.torn,
config.registryProxy,
],
});
const proposal = await factory_proposal.deploy(staking.target); const proposal = await factory_proposal.deploy(staking.address)
await sleep(20);
console.log( console.log("\nProposal 25 successfully deployed @ " + proposal.address + '\n')
"\nProposal 25 successfully deployed @ " + proposal.target + "\n"
);
await hre.run("verify:verify", { await hre.run('verify:verify', {
address: proposal.target, address: proposal.address,
constructorArguments: [staking.target], constructorArguments: [staking.address],
}); })
} }
main().then((res) => console.log(res ?? "\nScript finished.\n")); main().then((res) => console.log(res ?? "\nScript finished.\n"))