truffle-tutorial – 块菌教程区块链毕设代写

区块链毕设代写本文提供国外最新区块链项目源码下载,包括solidity,eth,fabric等blockchain区块链,truffle-tutorial – 块菌教程区块链毕设代写 是一篇很好的国外资料

truffle-tutorial

How to use and setup a working truffle environment:

  1. truffle init
  2. npm i the hd-wallet + openzeppelin
  3. Setup contract codes in the contracts folder
  4. Add infura, mnemonic, network details in truffle-config.js, remember to specify the version of the solc u want to use else u get an error when compiling.
  5. Add your mnemonic key inside a new .secrets file (eg. metamask wallet private key), add it to gitignore
  6. Delete the initial Migration.sol file
  7. truffle compile will compile the contract code and add them in the build folder
  8. Edit the initial 1_migration.js file inside migrations folder to your own contract code instead
  9. truffle migrate --network rinkeby for example will deploy the contract on the rinkeby network

Cheatsheet: https://eattheblocks.com/truffle-framework-cheatsheet/

Token setup:

  1. tokenContract: addToExcludeFromSlashFee() for vault and liquidity pool
  2. tokenContract: addToAuthorisedContracts() for vault
  3. depositVault: setTokenContractInstance() for token

块菌教程

如何使用和设置工作块菌环境:

  1. 块菌初始化
  2. npm i高清钱包+openzeppelin
  3. 在合同文件夹中设置合同代码
  4. 添加infura、助记符、,在truffle-config.js中,请记住指定要使用的solc版本,否则编译时会出错
  5. 在新的.secrets文件中添加助记键(例如metamask钱包私钥),将其添加到gitignore
  6. 删除初始Migration.sol文件
  7. truffle compile将编译合同代码并将其添加到构建文件夹中
  8. 将migrations文件夹中的初始1_Migration.js文件编辑到您自己的合同代码中
  9. truffle migrate–例如,network rinkeby将部署rinkeby网络上的合同

备忘:https://eattheblocks.com/truffle-framework-cheatsheet/

令牌设置:

  1. 代币合同:为保管库和流动性池添加ToExcludeFromsLashfee()
  2. 代币合同:为保管库添加授权合同()
  3. 存款保管库:为代币设置TokenContractInstance()

部分转自网络,侵权联系删除区块链源码网

www.interchains.cc

https://www.interchains.cc/23510.html

区块链毕设网(www.interchains.cc)全网最靠谱的原创区块链毕设代做网站 部分资料来自网络,侵权联系删除! 最全最大的区块链源码站 ! QQ3039046426
区块链知识分享网, 以太坊dapp资源网, 区块链教程, fabric教程下载, 区块链书籍下载, 区块链资料下载, 区块链视频教程下载, 区块链基础教程, 区块链入门教程, 区块链资源 » truffle-tutorial – 块菌教程区块链毕设代写

提供最优质的资源集合

立即查看 了解详情