Skip to content

CLI: hivec

Every SDK ships a hivec with the same four jobs: build a .hbc, inspect it, list its functions, and run a function on ndsr. ndsr is found through --ndsr/-ndsr (where supported), $NDSR_BIN, ndsr on PATH, or tools/ndsr in a parent directory.

hivec build [PATH] [OPTIONS]
--example <EXAMPLE> Build this example of the crate instead of its library
--name <NAME> Module name in the manifest [default: the cargo target / file name]
-o, --out <OUT> Output directory [default: dist]
--functions <FUNCTIONS> For a .wasm without a hivekit.functions section
--language <LANGUAGE> manifest.language for a .wasm input [default: rust]
--module-version <VERSION> Optional manifest.version
--description <DESCRIPTION> Optional manifest.description
--debug Build with the dev profile instead of --release
--target-dir <TARGET_DIR> Cargo target directory
hivec inspect FILE.hbc [--json]
hivec functions FILE # .hbc, .wasm or .rs source
hivec run <HBC> <FUNCTION> [INPUT]
--input-file <INPUT_FILE>
--gas <GAS>
--data-dir <DATA_DIR> Persist state/ledger here
--module <MODULES> Make another module callable via hive.call (repeatable)
--ndsr <NDSR> Path to the ndsr binary