engwarrior / capsule

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Capsule

A development framework for CKB contract, still in WIP phase.

The name "capsule" is from the dragon ball, which hints our goal is to provide an out-of-box solution.

Installation

Requirements

  • docker - capsule use docker to build contracts and run tests.
  • ckb-cli (optional) - capsule require ckb-cli to enable contracts deployment feature.

Make sure you installed the dependencies, and their binaries exist in the PATH.

Install preview version

cargo install capsule --git https://github.com/nervosnetwork/capsule.git --tag v0.0.1-pre.2

Usage

FLAGS:
    -h, --help       Prints help information
    -V, --version    Prints version information

SUBCOMMANDS:
    check     Check environment and dependencies
    new       Create a new project
    build     Build contracts
    test      Run tests
    deploy    Deploy contracts
    help      Prints this message or the help of the given subcommand(s)

Quick start

# check environment
capsule check

# create project
capsule new my-demo
cd my-demo
capsule build
capsule test

Project layout

  • capsule.toml - Capsule manifest file.
  • deployment.toml - Deployment configuration.
  • contracts - Contracts directory.
  • tests - Contracts tests.
  • build - Contracts binaries.
  • migrations - Deployment histories.

Documentation

WIKI homepage

LICENSE

MIT

About


Languages

Language:Rust 99.4%Language:Dockerfile 0.6%