Develop Task
Initialize from Template
To initialize a repository, use the following command:
This command will utilize the EVM template to create a new project, including contract code and a corresbonding Clique Task Manifest file. Here, "evm" specifies the use of the EVM template. During the subsequent build task phase, the contract code will be compiled to generate EVM bytecode, which will then be populated into the Manifest file (note that the bytecode format is different based on the VM you specify -- we plan to support WASM, RISC V, etc in the future).
How to Use
Before initialization, it is essential to establish an empty directory to serve as your workspace.
Project Structure
After initialization, the project structure is as follows:
/contracts/Main.sol
is the primary Solidity smart contract source file. This file contains the core smart contract logic and functionalities within the project.manifest.toml
is a clique task metadata written in TOML, including I/O schemas, proof types, and optional code or task sections depending on the task type. For more detailed information, please refer to Clique Manifestfoundry.toml
is a configuration file specific to the Foundry toolkit. You can use Foundry to compile and test your contracts. Foundry will also be required for the subsequent build phase to compile the contracts.
If you haven't set up the Foundry environment yet, run the following command in your terminal, then follow the onscreen instructions:
Develop Task
Upon completion of template initialization, you can modify the contract and manifest.toml
.
It is important to note that the contract entry point is fixed and must be Main.sol
. Users can import other contracts into Main.sol
.
After modifying the contracts, users should update manifest.toml
with new name
, input
and output
sections according to the changes made to the contracts. The code
section should be left empty, as it will be automatically populated by the CLI during build stage.
Last updated