基于区块链的毕业设计eth-template – eth模板

本文提供基于区块链的毕业设计国外最新区块链项目源码下载,包括solidity,eth,fabric等blockchain区块链,基于区块链的毕业设计eth-template – eth模板 是一篇很好的国外资料

eth-template

Bootstrapped Ethereum smart contract project template with truffle and ganache

Requirements

  • Installed npm packages npm install
  • IDE with solidity language support
  • (optional) Ethereum client (e.g. geth) for mainnet or testnet deployment

Directories

  • contracts – All the solidity contracts source code, with initial Migrations.sol used by truffle framework
  • migrations – Add migration scripts that are executed by truffle “migrate” command
  • scripts – Useful sandbox scripts as integration tests for deployed contracts on Ethereum network (mainnet or one of testnets)
  • tests – JavaScript test files executed by truffle “test” command, using mocha and chai libraries to test the main logic and behavior of smart contracts. Additionally, you could also write tests using Solidity and use provided truffle assertion libraries

Development steps

  1. Configure local development environmnet and other Ethereum networks configuration in truffle-config.js file
  2. Write smart contracts in ./contracts directory
  3. Compile contracts with command npm run compile
  4. Add new migration file or add deployment of new contracts in existing migration file in ./migrations directory
  5. Write tests in ./tests directory
  6. Run tests together with ganache-cli simulation network with command npm run ganache-run-test or run test on already running network node npm run test
  7. Deploy contracts on any configured network using npm run migrate
  8. (optional) Write additinal scripts to interact with smart contracts in ./scripts directory and execute them with command truffle exec scripts/sample.js

Contract templates and examples

Current Ethereum smart contract development standard for ERC-20 and ERC-721 tokens, and it’s example implementations can be found in following repository: https://github.com/OpenZeppelin/openzeppelin-contracts

Updated readme


eth模板

带truffle和ganache的引导式以太坊eth智能合约项目模板

要求

  • 安装的npm包npm安装
  • IDEsolidity语言支持
  • (可选)用于mainnet或testnet部署的以太坊eth客户端(例如geth)

目录

  • contracts-所有solidity contracts源代码,使用truffle framework使用的initial Migrations.sol
  • Migrations-添加由truffle“migrate”命令执行的迁移脚本
  • 脚本-有用的沙盒脚本作为以太坊eth网络(mainnet或其中一个测试网)上已部署契约的集成测试
  • 测试-truffle执行的JavaScript测试文件“test”命令,使用mocha和chai库测试智能合约的主要逻辑和行为。另外,您还可以使用Solidity编写测试,并使用提供的truffle断言库在truffle-config.js文件中配置本地开发环境和其他以太坊eth网络配置

开发步骤

  1. 在./contracts目录中编写智能合约
  2. 使用命令npm run Compile编译合约
  3. 添加新的迁移文件或在./migrations目录
  4. 的现有迁移文件中添加新协定的部署将测试写入./tests目录
  5. 使用命令npm Run ganache Run test或Run test on already running network node npm Run test在任何使用npm run migrate配置网络
  6. (可选)编写附加脚本以与./scripts目录中的智能合约交互,并使用命令truffle exec scripts/sample.js执行它们
  7. Deploy contracts on any configured network using npm run migrate
  8. (optional) Write additinal scripts to interact with smart contracts in ./scripts directory and execute them with command truffle exec scripts/sample.js

合同模板和示例

针对ERC-20和ERC-721代币的当前以太坊eth智能合约开发标准,它的示例实现可以在以下存储库中找到:https://github.com/OpenZeppelin/openzeppelin-contracts

Updated readme

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

www.interchains.cc

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

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

提供最优质的资源集合

立即查看 了解详情