Tangle CLI
Create and Deploy blueprints on Tangle Network.
Table of Contents
- Overview
- Installation
- Creating a New Blueprint/Gadget
- Deploying the Blueprint to a Local Tangle Node
- Required Environment Variables for Deployment
- Examples
Overview
The Tangle CLI is a command-line tool that allows you to create and deploy blueprints/gadgets on the Tangle network. It provides a simple and efficient way to manage your blueprints and gadgets, making it easy to get started with Tangle Blueprints.
Installation
To install the Tangle CLI, run the following command:
Supported on Linux, MacOS, and Windows (WSL2)
|
Or, if you prefer to install the CLI from source:
Creating a New Blueprint/Gadget
To create a new blueprint/gadget using the Tangle CLI, use the following command:
Replace <blueprint_name> with the desired name for your blueprint.
Example
Build The Blueprint and the Gadget
To build the blueprint and the gadget, you can simply use cargo as you would with any rust project:
Unit Testing
To run the unit tests, use the following command:
Deploying the Blueprint to a Local Tangle Node
To deploy the blueprint to a local Tangle node, use the following command:
# Substrate Signer account
# EVM signer account
Replace <rpc_url> with the RPC URL of your local Tangle node and <package_name> with the name of the package to
deploy.
Example
Expected output:
Blueprint #0 created successfully by 5F3sa2TJAWMqDhXG6jhV4N8ko9rUjC2q7z6z5V5s5V5s5V5s with extrinsic hash: 0x1234567890abcdef
Required Environment Variables for Deployment
The following environment variables are required for deploying the blueprint:
SIGNER: The SURI of the signer account.EVM_SIGNER: The SURI of the EVM signer account.
Example of ENV Variables
# Substrate Signer account
# EVM signer account