0

I am working windows 10 and have both

truffle.js

&

truffle-config.js

I am using command

truffle migrate --reset --networks rinkeby

Error produced: Unknown network "ganache". See your Truffle configuration file for available networks. Truffle v5.0.19 (core: 5.0.19)

Here's my truffle configuration:

 networks: {

      development: {
        host: "127.0.0.1",
        port: 7545,
        network_id: "5777", // Match any network id
        from: "0x55690752ed06B1d37510D20B3516b2D12F007f6d"
      },

      rinkeby: {
        provider: () => new HDWalletProvider(mnemonic, infura),
        network_id: 4,
        gas: 6700000,
        gasPrice : 10000000000
      }
  },

The configurations are same for both truffle.js & truffle-config.js

1
  • To begin with, on Windows, get rid of truffle.js if you want to be able to run truffle... command line. May 27, 2019 at 14:45

2 Answers 2

1

I'm sure an answer is no longer needed for this, but in case anyone else has the same problem, --networks should be --network.

1

Try running:

truffle deploy —network <network-name> —reset

And only use truffle-config.js if you r in windows.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.