npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

runar-cli

v0.2.0

Published

Rúnar CLI: compile, test, deploy, and manage smart contracts

Readme

runar-cli

Command-line tool for compiling, testing, deploying, and managing Rúnar smart contracts.

The CLI wraps the compiler, test runner, and SDK into a single runar command for everyday development workflow.


Installation

# Global install
pnpm add -g runar-cli

# Or use via npx
npx runar-cli compile MyContract.runar.ts

Commands

runar init [name]

Scaffold a new Rúnar project.

runar init my-contract

runar compile <files...>

Compile one or more contract files to Bitcoin Script.

# Compile a single file
runar compile contracts/P2PKH.runar.ts

# Compile multiple files
runar compile contracts/*.runar.ts

# Output to a specific directory
runar compile contracts/P2PKH.runar.ts -o ./out

# Include IR in artifact
runar compile contracts/P2PKH.runar.ts --ir

# Print ASM to stdout
runar compile contracts/P2PKH.runar.ts --asm

Options:

| Flag | Description | Default | |---|---|---| | -o, --output <dir> | Output directory for artifacts | ./artifacts | | --ir | Include ANF IR in the artifact | off | | --asm | Print ASM to stdout | off |

runar test [pattern]

Run contract tests.

# Run all tests
runar test

# Run tests matching a pattern
runar test P2PKH

runar codegen <files...>

Generate typed wrapper classes from compiled artifacts.

# Generate TypeScript wrappers from all artifacts
runar codegen artifacts/*.json -o src/generated/

# Generate from a single artifact
runar codegen artifacts/MyContract.json -o src/generated/

Options:

| Flag | Description | Default | |---|---|---| | -o, --output <dir> | Output directory for generated code | ./generated | | --lang <lang> | Target language (currently only ts) | ts |

Generated wrappers provide typed methods, hide auto-computed params (Sig, SigHashPreimage), and distinguish terminal from state-mutating methods. See Code Generation for details.

runar deploy <artifact>

Deploy a compiled contract to the BSV network.

runar deploy ./artifacts/P2PKH.json \
  --network testnet \
  --key cRkL4...

Options:

| Flag | Description | Default | |---|---|---| | --network <net> | mainnet or testnet | (required) | | --key <wif> | WIF-encoded private key for signing | (required) | | --satoshis <n> | Satoshis to lock in the contract UTXO | 10000 |

runar verify <txid>

Verify a deployed contract by fetching the transaction and checking the locking script against the artifact.

runar verify abc123def456... --artifact ./artifacts/P2PKH.json --network testnet

Options:

| Flag | Description | |---|---| | --artifact <path> | Path to the compiled artifact for comparison (required) | | --network <net> | Network to query (required) |


Example Workflow

# 1. Create a new project
runar init my-token

# 2. Compile
runar compile contracts/MyToken.runar.ts --ir

# 3. Run tests
runar test

# 4. Deploy to testnet
runar deploy ./artifacts/MyToken.json \
  --network testnet \
  --key cRkL4...

# 5. Verify the deployment
runar verify <txid> --artifact ./artifacts/MyToken.json --network testnet