Skip to content

Latest commit

 

History

History
72 lines (51 loc) · 2.21 KB

CONTRIBUTING.md

File metadata and controls

72 lines (51 loc) · 2.21 KB

Contributing to Iroha JavaScript

This document explains how this repo works, and how to work with it.

Pull Requests

  1. Install the Deno CLI.
  2. Install Node.js v22+.
    • And enable Corepack by corepack enable (making pnpm available).
  3. Install the Rust toolchain and wasm-pack.
    • Also make sure to install components: rustup component add rust-src --target wasm32-unknown-unknown.
  4. Clone & fork this repository.
  5. Link Iroha repository (see below).
  6. Create a new branch for your changes.
  7. Make your changes to the repo and ensure deno task ok passes successfully.
  8. Commit your changes with clear messages, preferably following Conventional Commits.
  9. Submit a pull request.

Linking & Building Iroha

For this project to function, you must link Iroha repository. There are two ways to do so.

Clone Iroha repository:

deno task prep:iroha --git https://github.com/hyperledger-iroha/iroha.git --git-rev v2.0.0-rc.1.0

Symlink to a local path:

deno task prep:iroha --path /path/to/local/iroha/clone

Making Releases

@deno/bump-workspaces could be of help:

deno run -A jsr:@deno/[email protected]/cli --dry-run

Guideline:

  1. Bump versions using the tool.
  2. Submit a PR with the changes of the versions and Releases.md.
  3. Merge, tag the commit in format release-2025-02-20, and push it.
  4. Create a release on GitHub at this tag, using the new piece of Releases.md as a description and date (e.g. "2025.02.20") as a title.

Setting Up Commit Hooks (optional)

You can add this to .git/hooks/pre-commit:

#!/bin/sh
deno task ok

Preview Docs

You can cd into a package directory (e.g. packages/core) and run these commands in parallel (requires watchexec and jq tools):

watchexec -e ts deno doc --html $(cat deno.json* | deno run npm:json5 | jq -r '.exports | .[]')
deno run -A npm:vite serve docs