Catalog npm
Back to packageRELEASE DETAILS

0.5.27

npm

@0xobelisk/sui-cli

Tookit for interacting with move eps framework

blockchainmoveobelisk labssui
Published7 Dec 2024
Direct dependencies24
Transitive dependenciesNot calculated

README

Current package documentation

The Dubhe CLI

The Dubhe CLI is used for building and developing a Dubhe project.

It comes with

  1. generate: Generate Move code from dubhe.config.ts
  2. publish: Deploy your own project on the specified sui network.
  3. upgrade: Upgrade your own project on the specified sui network.
  4. localnode: Start a local Sui node for development
  5. faucet: An interface to the Devnet/Localnet faucet. It makes it easy to fund addresses on the Devnet/localnet

Installation

We don't recommend installing the CLI globally.

Instead, you should add the CLI as a dev dependency to your project (done automatically if you start from a starter kit using pnpm create dubhe), and use it with pnpm build inside your project directory.

Using the CLI

Some commands expect a Dubhe config in the same folder where the CLI is being executed. This includes generate and publish.

faucet, and localnode can be executed anywhere.

Commands

generate

Generates Store libraries from a dubhe.config.ts file. See the Store Config and generate documentation in the Store section for more details.

# in a folder with a dubhe.config.ts
dubhe generate --config-path dubhe.config.ts

publish

Deploy a Dubhe contract project with the dubhe framework.

This tool will use the dubhe.config.ts to detect all systems, schemas and projectName in the project and will deploy them to the chain specified.

When using the deployer, you must set the private key of the deployer using the PRIVATE_KEY environment variable. You can make this easier by using dotenv before running dubhe publish in your deployment script.

To set up the target network for deploying the contract (mainnet/testnet/devnet/localnet), before deploying the contract, please make sure that you have some tokens in your account, which will be used for some fees when deploying the contract. (If you choose devnet/localnet, you can get some test tokens via dubhe faucet), if you need to deploy the contract on localnet, please make sure you have started localnode.

# to deploy sui locally
dubhe publish --network localnet
# to deploy to sui devnet
dubhe publish --network devnet
# to deploy to sui testnet
dubhe publish --network testnet
# to deploy to sui mainnet
dubhe publish --network mainnet

upgrade

Upgrade Dubhe contract project.

When you add a new schema or modify the system code, you need to upgrade the contract through the upgrade method. (Migration Guide)

dubhe upgrade --network <network:mainnet/testnet/devnet/localnet>

localnode

The localnode uses the official sui-test-validator binary provided by sui to start the localnode.

The local rpc is http://127.0.0.1:9000

dubhe localnode

faucet

Connects to a Dubhe faucet service to fund an address.

dubhe faucet --network <network:devnet/localnet>
dubhe faucet --network <network:devnet/localnet> --recipient <address>

The default faucet service automatically gives test tokens to accounts in dotenv.

To fund an address on the devnet/localnet, run dubhe faucet --recipient <address>

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Declared dependencies 24

Native requirements
24 direct targetsNot calculated transitive count
Package / targetRequirementRelationship
ejs
Environment
{
  "local_name": "ejs",
  "alias": false,
  "peer_metadata": null
}
^3.1.8runtime
zod
Environment
{
  "local_name": "zod",
  "alias": false,
  "peer_metadata": null
}
^3.22.3runtime
glob
Environment
{
  "local_name": "glob",
  "alias": false,
  "peer_metadata": null
}
^8.0.3runtime
path
Environment
{
  "local_name": "path",
  "alias": false,
  "peer_metadata": null
}
^0.12.7runtime
chalk
Environment
{
  "local_name": "chalk",
  "alias": false,
  "peer_metadata": null
}
^5.0.1runtime
execa
Environment
{
  "local_name": "execa",
  "alias": false,
  "peer_metadata": null
}
^7.0.0runtime
yargs
Environment
{
  "local_name": "yargs",
  "alias": false,
  "peer_metadata": null
}
^17.7.1runtime
dotenv
Environment
{
  "local_name": "dotenv",
  "alias": false,
  "peer_metadata": null
}
^16.0.3runtime
prettier
Environment
{
  "local_name": "prettier",
  "alias": false,
  "peer_metadata": null
}
^2.8.4runtime
typescript
Environment
{
  "local_name": "typescript",
  "alias": false,
  "peer_metadata": null
}
5.1.6runtime
@mysten/sui
Environment
{
  "local_name": "@mysten/sui",
  "alias": false,
  "peer_metadata": null
}
^1.7.0runtime
child_process
Environment
{
  "local_name": "child_process",
  "alias": false,
  "peer_metadata": null
}
^1.0.2runtime
prettier-plugin-rust
Environment
{
  "local_name": "prettier-plugin-rust",
  "alias": false,
  "peer_metadata": null
}
^0.1.9runtime
zod-validation-error
Environment
{
  "local_name": "zod-validation-error",
  "alias": false,
  "peer_metadata": null
}
^1.3.0runtime
@0xobelisk/sui-client
Environment
{
  "local_name": "@0xobelisk/sui-client",
  "alias": false,
  "peer_metadata": null
}
^0.5.28runtime
@0xobelisk/sui-common
Environment
{
  "local_name": "@0xobelisk/sui-common",
  "alias": false,
  "peer_metadata": null
}
^0.5.22runtime
tsx
Environment
{
  "local_name": "tsx",
  "alias": false,
  "peer_metadata": null
}
^3.12.6development
tsup
Environment
{
  "local_name": "tsup",
  "alias": false,
  "peer_metadata": null
}
^6.7.0development
vitest
Environment
{
  "local_name": "vitest",
  "alias": false,
  "peer_metadata": null
}
0.31.4development
ts-node
Environment
{
  "local_name": "ts-node",
  "alias": false,
  "peer_metadata": null
}
^10.9.1development
@types/ejs
Environment
{
  "local_name": "@types/ejs",
  "alias": false,
  "peer_metadata": null
}
^3.1.1development
@types/glob
Environment
{
  "local_name": "@types/glob",
  "alias": false,
  "peer_metadata": null
}
^7.2.0development
@types/node
Environment
{
  "local_name": "@types/node",
  "alias": false,
  "peer_metadata": null
}
^18.15.11development
@types/yargs
Environment
{
  "local_name": "@types/yargs",
  "alias": false,
  "peer_metadata": null
}
^17.0.10development

Distribution files

1 collected
Distribution 1

Source distribution

Source file
Checksums from source
{
  "shasum": "580af53e7d66dae55f8247dcc099cfa5d1381321",
  "tarball": "https://registry.npmjs.org/@0xobelisk/sui-cli/-/sui-cli-0.5.27.tgz",
  "fileCount": 25,
  "integrity": "sha512-/13AXrVFjsTENkQjRbMKs/YKhXklKvxDjRFWNmW7aXHL+Cniw2zCKhWuLAcPL0n5ihptb8lJQ6iX9/dBeUayeg==",
  "signatures": [
    {
      "sig": "MEUCIHrSKs+iGpbWMZYS7XnsjnxTAVPkNkM/MZDr9Wf3l8gOAiEAiTkWqOihyZz2uPxlH2zdTMHrtIZgGI1nZoH24d6pYt8=",
      "keyid": "SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"
    }
  ],
  "unpackedSize": 157716
}

Repository

PENDING
0xobelisk/obelisk-engine

Shared repository data · GitHub

License detected in repository
Not collected

Repository

PENDING
0xobelisk/dubhe

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 21 Oct, 09:21 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package_version:7a48163589eb78330c109bd07ef7ddd35c57bf4ea3417c0ec8a82bb16f4ac86e

Other collected versions

2.0.029 Jun1.2.0-pre.12522 Jun1.2.0-pre.12419 May1.2.0-pre.12318 May1.2.0-pre.12213 May1.2.0-pre.12112 MayView all collected versions →