Hello,
I have deployed an upgradable ERC20 token using ^0.8.4 and I would like to set up an AllocatedCrowdsale for said token. I have set up a second project for the crowdsale using ^0.5.0 but I'm struggling to find a way to link to my previously deployed token. This is as far as I've got so far deploying with Truffle:
const MyCrowdsale = artifacts.require("MyCrowdsale");
module.exports = async function (deployer, network, accounts) {
const token = "MY TOKEN CONTRACT ADDRESS";
await deployer.deploy(MyCrowdsale, 1000, accounts[0], token.address, accounts[0]);
const crowdsale = await MyCrowdsale.deployed();
token.transfer(crowdsale.address, 10000)
};
Any advice much appreciated.
Cheers,