diff --git a/package.json b/package.json index d9cca6ee2..b78942e37 100644 --- a/package.json +++ b/package.json @@ -82,7 +82,7 @@ "build": "SKIP_LOAD=true scripts/build", "clean": "rm -rf build/ cache/ dist/", "compile": "hardhat compile", - "deploy": "yarn build && scripts/predeploy && hardhat migrate", + "deploy": "yarn build && yarn predeploy && hardhat migrate", "deploy-localhost": "yarn deploy --force --network localhost --graph-config config/graph.localhost.yml", "deploy-rinkeby": "yarn deploy --force --network rinkeby --graph-config config/graph.rinkeby.yml", "deploy-goerli": "yarn deploy --force --network goerli --graph-config config/graph.goerli.yml", diff --git a/tasks/deployment/accounts.ts b/tasks/deployment/accounts.ts index d26102beb..a84d6990d 100644 --- a/tasks/deployment/accounts.ts +++ b/tasks/deployment/accounts.ts @@ -6,10 +6,6 @@ import { updateItemValue, writeConfig } from '../../cli/config' task('migrate:accounts', '[localhost] Creates protocol accounts and saves them in graph config') .addParam('graphConfig', cliOpts.graphConfig.description, cliOpts.graphConfig.default) .setAction(async (taskArgs, hre) => { - if (hre.network.name !== 'localhost') { - throw new Error('This task can only be run on localhost network') - } - const { graphConfig, getDeployer } = hre.graph({ graphConfig: taskArgs.graphConfig, }) diff --git a/tasks/deployment/ownership.ts b/tasks/deployment/ownership.ts index 83b4e6485..8b711d0af 100644 --- a/tasks/deployment/ownership.ts +++ b/tasks/deployment/ownership.ts @@ -9,10 +9,6 @@ task( .addParam('addressBook', cliOpts.addressBook.description, cliOpts.addressBook.default) .addParam('graphConfig', cliOpts.graphConfig.description, cliOpts.graphConfig.default) .setAction(async (taskArgs, hre) => { - if (hre.network.name !== 'localhost') { - throw new Error('This task can only be run on localhost network') - } - const { contracts, getNamedAccounts } = hre.graph({ addressBook: taskArgs.addressBook, graphConfig: taskArgs.graphConfig,