The Cartesi Co-Processor CLI Tool simplifies bootstrapping, registering, and deploying Cartesi co-processor programs. This tool streamlines the development workflow for Cartesi-based applications, allowing developers to focus on building their logic instead of wrestling with setup and deployment processes.
- Bootstrap Projects: Quickly initialize a Cartesi project with a simple Foundry project inheriting the co-processor base contracts.
- Simplified Registration: Easily build, generate .car files and finally update the co-processor task issuer with your program/machine details.
- Simplified Deployment: Automate the deployment and registration of co-processor programs.
Ensure you have Rust and Cargo installed. You can then install the CLI tool directly from crates.io:
cargo install cartesi-coprocessor
Clone the repository and build the tool manually:
git clone https://github.com/Mugen-Builders/co-processor-cli
cd co-processor-cli
cargo install --path .
- You need to have all the necessary dependencies installed and running before you can use this tool.
- Nonodo.
- Docker.
- Cartesi machine.
- Carize.
- W3 (web3 storage CLI).
- foundry.
- You need to clone and build the Carize tool manually also before calling any of the commands.
Run the CLI tool with:
cartesi-coprocessor [COMMAND] [OPTIONS]
Initialize a new Foundry project with Cartesi base contracts:
cartesi-coprocessor create --dapp-name <project_name> --template <language template>
Register your Cartesi co-processor program:
cartesi-coprocessor register --email <w3 storage account email>
- Bootstrap a Project
cartesi-coprocessor create --dapp-name my-cartesi-project --template rust
cd my-cartesi-project
-
Add Logic to the Child Contract Edit the pre-generated child contract in the
src
folder to implement your business logic. -
Register the Program
cartesi-coprocessor register --email [email protected]
We welcome contributions! To get started:
- Fork the repository.
- Create a new branch:
git checkout -b feature-name
- Make your changes and test them.
- Submit a pull request.
This project is licensed under the MIT License. See the LICENSE file for details.
If you encounter issues or have feature requests, please open an issue on GitHub. Or drop a message on Cartesi discord under the Co-Procesor thread.