1

I installed truffle via this command:

sudo npm install -g truffle  

Then I installed testrpc via this command

sudo npm install -g ethereumjs-testrpc  

Then I started testrpc via this command

testrpc  

It began to run successfully. Then I created a folder and initiated truffle project via this command.

truffle init  

Then I compiled it via this command

truffle compile  

Then I migrated that truffle project via this command

truffle migrate  

Now I want to add DAPPS support, so I built that truffle project via this command

truffle build  

But when I ran that command, I got this error

Error building:

No build configuration specified. Can't build.

Build failed. See above.  

My truffle version is

Truffle v3.4.9 (core: 3.4.8)
Solidity v0.4.15 (solc-js)  

How can I fix that error, it seems to be a bug as given here.

2 Answers 2

2

You need to create a build process. http://truffleframework.com/docs/advanced/build_processes

It is stated in their documentation:

Note you'll receive an error if you try to run the build command without first configuring a custom build process.

1

You need to have a file in the home folder called truffle.js This should be created automatically when you type in truffle init Then you need to modify this file. an example of mine pointing to my local testrpc looks like this

module.exports = {
  networks: {
     development: {
       host: "localhost",
       port: 8545,
       network_id: "*" // Match any network id
     }
   },
   mocha: {
    useColors: true
   }
};

But if you are not using the testRPC and using truffles own test engine, then comment out the block as follows:

module.exports = {
  networks: {
  //  testrpc: {
  //    host: "localhost",
  //    port: 8545,
  //    network_id: "*" // Match any network id
  //  }
  }
};

This should work currently.

Your Answer

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

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