Truffle can be initialized by running the following command. First, create a directory for the project, for example:
$ mkdir testdapp
Then, change directory to testdapp and run the following command:
$ truffle init Downloading... Unpacking... Setting up... Unbox successful. Sweet! Commands: Compile: truffle compile Migrate: truffle migrate Test contracts: truffle test
Once the command is successful, it will create the directory structure shown here. This can be viewed using the tree command in Linux:
$ tree . ├── contracts │ └── Migrations.sol ├── migrations │ └── 1_initial_migration.js ├── test ├── truffle-config.js └── truffle.js 3 directories, 4 files
This command creates three main directories, named contracts ...