[Contract] Truffle 入门流程

Installation

$ npm install -g truffle

Choose ethereum client (Ganache OR truffle build in `truffle develop`)

https://www.trufflesuite.com/docs/truffle/reference/choosing-an-ethereum-client

Creating a project

$ truffle unbox <box-name>  # box-name like metacoin

扫描二维码关注公众号,回复: 9196062 查看本文章

OR

$ truffle init  # without default contract

Compiling Contracts

$ truffle compile  # all placed in build/contracts/, dot not edit these .json files

Running Migrations

$ truffle migrate  # run scripts that located in migrations/,Be sure have Ganache installed and running

Deployer https://www.trufflesuite.com/docs/truffle/getting-started/running-migrations#deployer

docs:https://www.trufflesuite.com/docs/truffle/getting-started/installation

link:https://www.cnblogs.com/farwish/p/12310551.html

猜你喜欢

转载自www.cnblogs.com/farwish/p/12310551.html
今日推荐