1
votes

I am trying to make a sample smart contract and migrate to ether scan explorer but not able to deploy. I am using truffle, infura and metamask to test my application. i am able to compile it successfully but when i try to run migrate it says everything is upto date, nothing to compile. My truffle.js file looks like this

    ropsten: {
      provider: function (){
        return new HDWalletProvider(mnemonic, 
        'https://ropsten.infura.io/v3/api_key')
      },
      network_id: 3,
      from: 'address',
      gasPrice: 25000000000000
    }
}
1

1 Answers

1
votes

You have to select the network:

$ truffle deploy --network ropsten

See truffle docs.