Skip to content

Commit

Permalink
Merge pull request #338 from huvny-de/master
Browse files Browse the repository at this point in the history
Feat utils.mdx
  • Loading branch information
cwgoes authored May 18, 2024
2 parents feb72dd + 9fded8f commit 0ccaa4d
Show file tree
Hide file tree
Showing 3 changed files with 119 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/docs/pages/_meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,6 @@
"users": "User Guide",
"operators": "Operator Guide",
"integrating-with-namada" : "Integration Guide",
"networks": "Networks"
}
"networks": "Networks",
"utils": "Utils"
}
2 changes: 2 additions & 0 deletions packages/docs/pages/introduction/quick-start.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ If you build from source, and run `make install`, the binaries will be installed

See [the networks page](../networks.mdx) for details on how to join a network. The rest of this guide will assume you have joined a network using the `namadac utils join-network --chain-id <some-chain-id>` command.

See [all utilities command](../utils.mdx).

## Run a ledger node

We recommend this step with [tmux](https://www.hamvocke.com/blog/a-quick-and-easy-guide-to-tmux/), which allows the node to keep running without needing the terminal to be open indefinitely. If not, skip to the subsequent step.
Expand Down
114 changes: 114 additions & 0 deletions packages/docs/pages/utils.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,114 @@
# Commands

Usage: `namadac utils [OPTIONS] <COMMAND>`

## join-network

Configure Namada to join an existing network.
See [the networks page](../networks.mdx) for details on how to join a network.
```shell copy
namadac utils join-network --chain-id <some-chain-id>
```

## fetch-wasms

Ensure pre-built wasms are present.
```shell copy
namadac utils fetch-wasms --chain-id <chain-id>
```


## validate-wasm

Check that the provided wasm code is valid by the Namada standards.
```shell copy
namadac utils validate-wasm --code-path <code-path> --chain-id <chain-id>
```

## init-network

Initialize a new test network.

```shell copy
namadac utils init-network --templates-path <templates-path> --wasm-checksums-path <wasm-checksums-path>
--chain-prefix <chain-prefix> --genesis-time <genesis-time> --chain-id <chain-id>
```

## derive-genesis-addresses

Derive account addresses from a genesis txs toml file.
```shell copy
namadac utils derive-genesis-addresses --path <path> --chain-id <chain-id>
```

## genesis-bond

Bond to a validator at pre-genesis.
```shell copy
namadac utils genesis-bond --validator <validator> --amount <amount> --path <path> --chain-id <chain-id>
```

## init-genesis-established-account

Initialize an established account available at genesis.
```shell copy
namadac utils init-genesis-established-account --path <path> --chain-id <chain-id>
```

## init-genesis-validator

Initialize genesis validator's address, consensus key and validator account key and use it in the ledger's node. Appends validator creation and self-bond txs to a .toml file containing an established account tx.
```shell copy
namadac utils init-genesis-validator --alias <alias> --address <address> --path <path>
--net-address <net-address> --commission-rate <commission-rate> --max-commission-rate-change <max-commission-rate-change>
--self-bond-amount <self-bond-amount> --email <email> --chain-id <chain-id>
```

## pk-to-tm

Convert a validator's consensus public key to a Tendermint address.
```shell copy
namadac utils pk-to-tm --public-key <public-key> --chain-id <chain-id>
```

## default-base-dir

Print the default base directory that would be used if --base-dir or NAMADA_BASE_DIR were not used to set the base directory.
```shell copy
namadac utils default-base-dir
```

## epoch-sleep

Query for the current epoch, then sleep until the next epoch.
```shell copy
namadac utils epoch-sleep
```

## validate-genesis-templates

Validate genesis templates.
```shell copy
namadac utils validate-genesis-templates --path <path> --chain-id <chain-id>
```

## test-genesis

Dry run genesis files and get a report on problems that may be found.
```shell copy
namadac utils test-genesis --path <path> --chain-id <chain-id>
```

## sign-genesis-txs

Sign genesis transaction(s).
```shell copy
namadac utils sign-genesis-txs --path <path> --chain-id <chain-id>
```

## help

Print this message or the help of the given subcommand(s).
```shell copy
namadac utils [COMMAND] --help
```

0 comments on commit 0ccaa4d

Please sign in to comment.