I'm trying to run an external script in truffle. Basically I deploy the contracts with 'migrate' then want to run this script to set the variables. I just can't seem to get it to call correctly with:
truffle develop
compile
migrate
exec file.js
and my code:
var Factory = artifacts.require("Factory");
module.exports = async function(callback) {
var factory = await Factory.deployed();
console.log(factory.address);
await factory.setVariables(1000000000000000,1000000000000000,7,1);
}
The console logs the correct address, but then it just hangs on the last part. Any help is much appreciated!