@rosen-bridge/cli
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

@rosen-bridge/cli

Table of contents

Introduction

@rosen-bridge/cli is the official Rosen bridge cli, providing helpers for the tasks related to Rosen bridge.

Installation

npm:

npm i @rosen-bridge/cli

yarn:

yarn add @rosen-bridge/cli

Usage

The cli can be used through npx.

npx @rosen-bridge/cli --help

download-assets

Downloads Rosen bridge assets (tokens and addresses files) from contracts repository on GitHub for a specific chain type (e.g. mainnet, etc.).

npx @rosen-bridge/cli download-assets --help

Examples

Download assets for mainnet into a rosen directory.

npx @rosen-bridge/cli download-assets --chain-type mainnet --out rosen

docker solution:

docker run -it --rm -v "$PWD"/rosen:/usr/src/app/rosen -w /usr/src/app node:20.11 npx --yes @rosen-bridge/cli download-assets --chain-type mainnet --out rosen

Download assets for testnet into a rosen directory. If some pre-releases are available for testnet, download them. Add suffix foo to all downloaded asset names.

npx @rosen-bridge/cli download-assets -c testnet -o rosen --include-prereleases --suffix foo

tss-secret

Generate Tss publicKey/secret for ecdsa or eddsa.

npx @rosen-bridge/cli tss-secret -t ecdsa generate
npx @rosen-bridge/cli tss-secret -t eddsa generate

docker solution for ecdsa:

docker run -it --rm node:20.11 npx --yes @rosen-bridge/cli tss-secret -t ecdsa generate

Convert secret to pk:

npx @rosen-bridge/cli tss-secret -t ecdsa convert-to-pk YOUR_TSS_SECRET
npx @rosen-bridge/cli tss-secret -t eddsa convert-to-pk YOUR_TSS_SECRET

docker solution for ecdsa:

docker run -it --rm node:20.11 npx --yes @rosen-bridge/cli tss-secret -t ecdsa convert-to-pk YOUR_TSS_SECRET

blake2b-hash

blake2b hash of specified input

npx @rosen-bridge/cli blake2b-hash [input]

Examples

Get blake2b hash from hello

npx @rosen-bridge/cli blake2b-hash hello

docker solution:

docker run -it --rm node:20.11 npx --yes @rosen-bridge/cli blake2b-hash hello

Readme

Keywords

Package Sidebar

Install

npm i @rosen-bridge/cli

Weekly Downloads

210

Version

1.0.0

License

GPL-3.0

Unpacked Size

144 kB

Total Files

10

Last publish

Collaborators

  • zargarzadehm
  • vorujack