1.1.1 • Published 10 months ago

canister-tools v1.1.1

Weekly downloads
-
License
-
Repository
-
Last release
10 months ago

Canister Tools

A comprehensive CLI toolkit for ICP. These are shortened dfx commands into single scripts that are excecutable

Features

  • 🔄 Automated canister upgrade process
  • 📝 Candid (.did) file generation for Rust canisters
  • 🌐 Support for both local and mainnet deployments
  • 🎯 Handles both frontend and backend canisters

Installation

npm install -g canister-tools

Tools Available

1. Candid File Generator:

Automatically generates .did files for Rust canisters.

Usage:

npx generate-did <canister_name>

Example:

generate-did backend

This will: 1. Build the Rust canister 2. Extract and generate the Candid file 3. Save it as <canister_name>.did

2. Canister Upgrader:

Streamlines the process of upgrading Internet Computer canisters.

Frontend Canister Upgrades

Local Development:

upgrade-canister <frontend_canister_name> --frontend

Mainnet Deployment:

upgrade-canister <frontend_canister_name> --frontend --mainnet

Backend Canister Upgrades

Local Development:

upgrade-canister <backend_canister_name> --backend

Mainnet Deployment:

upgrade-canister <backend_canister_name> --backend --mainnet

How It Works:

Frontend Upgrade Process

  • Builds the canister
  • Performs the upgrade installation
  • Handles network-specific configurations

Backend Upgrade Process

  • Builds the canister
  • Locates the correct Wasm file
  • Fetches the canister ID

Executes the upgrade with proper network paths

Command Options
Options:
  --frontend, -f  Upgrade a frontend canister
  --backend, -b   Upgrade a backend canister
  --mainnet, -m   Deploy to mainnet (IC network)
  --help          Show help information

Requirements

  • Node.js installed
  • DFX CLI installed
  • Internet Computer project setup
1.1.1

10 months ago

1.1.0

10 months ago

1.0.9

10 months ago

1.0.8

10 months ago

1.0.7

10 months ago

1.0.6

10 months ago

1.0.5

10 months ago

1.0.4

10 months ago

1.0.3

10 months ago