Skip to content

brunoamancio/IOTA-SmartContracts

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Template used to implement IOTA smart contracts

A simple template used to start developing your own smart contracts for ISCP (IOTA Smart Contract Protocol) in Rust and write unit tests in Go. In order to develop using the environment set up by this template, you need to have good understanding of the Rust and Go languages.

This is a repository for myself but I welcome anyone interested in playing around with the current state of development of the IOTA Smart Contract Protocol (ISCP). Feel free to contact me on IOTA Foundation's discord server under Th3B0Y#8380.

Simple structure prepared to start with development right away

This is how the templated file structure looks like:

View of the template on VSCode


Requirements

Set code up!

  • Use this template repository to create your own.
  • Open VSCode and a terminal in it (In the menu : Terminal > New Terminal)
  • In the terminal, clone your git repository:
git clone <your_git_repository> && cd <your_git_repositories_name>
  • In the terminal, open your git repository on VSCode
code -r .
  • For Windows only, open file ".vscode/settings.json" and uncomment the setting "go.testFlags" entry "-buildmode=exe": Go.testFlags for Windows
  • On VSCode, open the replace functionality (Edit > Replace in files)
    • Replace brunoamancio/IOTA-SmartContracts for <your_username>/<your_project_name> [How to]

Done! Now you can write your smart contract in smartcontract/rust, compile it, run and debug unit tests in tests/smartcontract/my_iota_smart_contract_test.go!


MIT License