From 26e2cc7ea28371ef935174ad97a9f3bbcd1959ef Mon Sep 17 00:00:00 2001 From: HaoyangLiu Date: Sat, 17 Nov 2018 13:34:35 +0800 Subject: [PATCH 1/5] Move all global flags to cli-client/README.md, and refactor stake and distribution interface --- docs/cli-client/README.md | 54 +++++++++ docs/cli-client/distribution/README.md | 111 ++++-------------- .../distribution/delegation-distr-info.md | 38 ++++++ .../distribution/delegator-distr-info.md | 42 +++++++ .../distribution/set-withdraw-address.md | 28 +++++ .../distribution/validator-distr-info.md | 43 +++++++ .../distribution/withdraw-address.md | 33 ++++++ .../distribution/withdraw-rewards.md | 41 +++++++ docs/cli-client/stake/README.md | 17 ++- docs/cli-client/stake/create-validator.md | 61 ++++------ docs/cli-client/stake/delegate.md | 36 ++---- docs/cli-client/stake/edit-validator.md | 54 +++------ docs/cli-client/stake/redelegate.md | 45 +++---- docs/cli-client/stake/unbond.md | 41 +++---- docs/cli-client/stake/unjail.md | 40 ++----- 15 files changed, 399 insertions(+), 285 deletions(-) create mode 100644 docs/cli-client/distribution/delegation-distr-info.md create mode 100644 docs/cli-client/distribution/delegator-distr-info.md create mode 100644 docs/cli-client/distribution/set-withdraw-address.md create mode 100644 docs/cli-client/distribution/validator-distr-info.md create mode 100644 docs/cli-client/distribution/withdraw-address.md create mode 100644 docs/cli-client/distribution/withdraw-rewards.md diff --git a/docs/cli-client/README.md b/docs/cli-client/README.md index c1901202e..f72b62dcc 100644 --- a/docs/cli-client/README.md +++ b/docs/cli-client/README.md @@ -1 +1,55 @@ # CLi Client + +## Global flags for query commands + +All query commands has their unique flags and these global flags. + +| Name, shorthand | type | Required | Default Value | Description | +| --------------- | ---- | -------- | --------------------- | -------------------------------------------------------------------- | +| --chain-id | string | false | "" | Chain ID of tendermint node | +| --height | int | false | 0 | block height to query, omit to get most recent provable block | +| --help, -h | string | false | | help for delegation | +| --indent | bool | false | false | Add indent to JSON response | +| --ledger | bool | false | false | Use a connected Ledger device | +| --node | string | false | tcp://localhost:26657 | \:\ to tendermint rpc interface for this chain | +| --trust-node | bool | false | true | Don't verify proofs for responses | + +## Global flags for commands to send transactions + +All commands which can be used to send transactions has their unique flags and these global flags. + +| Name, shorthand | type | Required | Default | Description | +| -----------------| ----- | -------- | --------------------- | ------------------------------------------------------------------- | +| --account-number | int | false | 0 | AccountNumber number to sign the tx | +| --async | bool | false | false | broadcast transactions asynchronously | +| --chain-id | string | true | "" | Chain ID of tendermint node | +| --dry-run | bool | false | false | Ignore the --gas flag and perform a simulation of a transaction, but don't broadcast it | +| --fee | string | true | "" | Fee to pay along with transaction | +| --from | string | false | "" | Name of private key with which to sign | +| --from-addr | string | false | "" | Specify from address in generate-only mode | +| --gas | int | false | 200000 | Gas limit to set per-transaction; set to "simulate" to calculate required gas automatically | +| --gas-adjustment | int | false | 1 | Adjustment factor to be multiplied against the estimate returned by the tx simulation; if the gas limit is set | +| --generate-only | bool | false | false | Build an unsigned transaction and write it to STDOUT | +| --help, -h | string | false | | Help for delegate | +| --indent | bool | false | false | Add indent to JSON response | +| --json | string | false | false | Return output in json format | +| --ledger | bool | false | false | Use a connected Ledger device | +| --memo | string | false | "" | Memo to send along with transaction | +| --node | string | false | tcp://localhost:26657 | \:\ to tendermint rpc interface for this chain | +| --print-response | bool | false | false | return tx response (only works with async = false)| +| --sequence int | int | false | 0 | Sequence number to sign the tx | +| --trust-node | bool | false | true | Don't verify proofs for responses | + +## Command list + +1. [bank command](./bank/README.md) +2. [distribution command](./distribution/README.md) +3. [gov command](./gov/README.md) +4. [keys command](./keys/README.md) +5. [lcd command](./lcd/README.md) +6. [record command](./record/README.md) +7. [service command](./service/README.md) +8. [stake command](./stake/README.md) +9. [status command](./status/README.md) +10. [tendermint command](./tendermint/README.md) +11. [upgrade command](./upgrade/README.md) diff --git a/docs/cli-client/distribution/README.md b/docs/cli-client/distribution/README.md index e3facf88f..e7dca38c8 100644 --- a/docs/cli-client/distribution/README.md +++ b/docs/cli-client/distribution/README.md @@ -1,99 +1,28 @@ -# Introduction +# iriscli distribution -This document description how to use the the command line interface of distribution module. - -# Query interface - -By default, trust-node mode is enable. If you don't trust the connected node, just append --trust-node=false in each query command. - -1. Query withdraw address - - For example: - ```bash - iriscli distribution withdraw-address faa1vm068fnjx28zv7k9kd9j85wrwhjn8vfsxfmcrz - ``` - If the given delegator doesn't specify other withdraw address, the query result will be empty. +## Description -2. Query delegation distribution information - - For example: - ```bash - iriscli distribution delegation-distr-info --address-delegator=faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j \ - --address-validator=fva1ezzh0humhy3329xg4avhcjtay985nll0hpyhf4 - ``` - Query result: - ```json - { - "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", - "val_operator_addr": "fva1ezzh0humhy3329xg4avhcjtay985nll0hpyhf4", - "del_pool_withdrawal_height": "4044" - } - ``` - The above response means this delegator has send transaction to withdraw reward at height 4044 or the delegation is created on height 4044. - -2. Query delegator distribution information - - For example: - ```bash - iriscli distribution delegator-distr-info faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j - ``` - Query result: - ```json - [ - { - "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", - "val_operator_addr": "fva14a70gzu0v2w8dlfx462c9sldvja24qaz6vv4sg", - "del_pool_withdrawal_height": "10859" - }, - { - "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", - "val_operator_addr": "fva1ezzh0humhy3329xg4avhcjtay985nll0hpyhf4", - "del_pool_withdrawal_height": "4044" - } - ] - ``` +This document description how to use the the command line interface of distribution module. -4. Query validator distribution information +## Usage - For example: - ```bash - iriscli distribution delegator-distr-info faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j - ``` - Query result: - ```json - { - "operator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", - "fee_pool_withdrawal_height": "416", - "del_accum": { - "update_height": "416", - "accum": "0.0000000000" - }, - "del_pool": "0.0000000000iris", - "val_commission": "0.0000000000iris" - } - ``` +```shell +iriscli distribution [subcommand] +``` -# Send transactions interface +Print all supported subcommands and options: -1. Set withdraw address +```shell +iriscli distribution --help +``` - Validator operators or delegators can specify other address as their withdraw address. If no other address has been specified, the delegator address or validator self-delegator address will be used as default address. - For example: - ```bash - iriscli distribution set-withdraw-addr faa1syva9fvh8m6dc6wjnjedah64mmpq7rwwz6nj0k --from mykey --fee=0.004iris --chain-id=irishub-test - ``` - -2. withdraw rewards +## Available Commands - 1. Only withdraw the delegation reward from a given validator - ```bash - iriscli distribution withdraw-rewards --only-from-validator fva134mhjjyyc7mehvaay0f3d4hj8qx3ee3w3eq5nq --from mykey --fee=0.004iris --chain-id=irishub-test - ``` - 2. Withdraw all delegation reward of a delegator - ```bash - iriscli distribution withdraw-rewards --from mykey --fee=0.004iris --chain-id=irishub-test - ``` - 3. If the delegator is a onwer of a validator, withdraw all delegation reward and validator reward: - ```bash - iriscli distribution withdraw-rewards --is-validator=true --from mykey --fee=0.004iris --chain-id=irishub-test - ``` \ No newline at end of file +| Name | Description | +| --------------------------------| --------------------------------------------------------------| +| [delegation-distr-info](delegation-distr-info.md) | Query delegation distribution information | +| [delegator-distr-info](delegator-distr-info.md) | Query delegator distribution information | +| [validator-distr-info](validator-distr-info.md) | Query validator distribution information | +| [withdraw-address](withdraw-address.md) | Query withdraw address | +| [set-withdraw-address](set-withdraw-address.md) | change the default withdraw address for rewards associated with an address | +| [withdraw-rewards](withdraw-rewards.md) | withdraw rewards for either: all-delegations, a delegation, or a validator | diff --git a/docs/cli-client/distribution/delegation-distr-info.md b/docs/cli-client/distribution/delegation-distr-info.md new file mode 100644 index 000000000..a070ac4fa --- /dev/null +++ b/docs/cli-client/distribution/delegation-distr-info.md @@ -0,0 +1,38 @@ +# iriscli distribution delegation-distr-info + +## Description + +Query delegation distribution information + +## Usage + +``` +iriscli distribution delegation-distr-info [flags] +``` + +Print all supported options: + +```shell +iriscli distribution delegation-distr-info --help +``` + +## Unique Flags + +| Name, shorthand | type | Required | Default | Description | +| --------------------| ----- | -------- | -------- | ------------------------------------------------------------------- | +| --address-validator | string | true | "" | Bech address of the validator | +| --address-delegator | string | true | "" | Bech address of the delegator | + +## Examples + +```shell +iriscli distribution delegation-distr-info --address-delegator= --address-validator= +``` +Example response: +```json +{ + "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", + "val_operator_addr": "fva1ezzh0humhy3329xg4avhcjtay985nll0hpyhf4", + "del_pool_withdrawal_height": "4044" +} +``` \ No newline at end of file diff --git a/docs/cli-client/distribution/delegator-distr-info.md b/docs/cli-client/distribution/delegator-distr-info.md new file mode 100644 index 000000000..1fa122735 --- /dev/null +++ b/docs/cli-client/distribution/delegator-distr-info.md @@ -0,0 +1,42 @@ +# iriscli distribution delegator-distr-info + +## Description + +Query delegator distribution information + +## Usage + +``` +iriscli distribution delegator-distr-info [flags] +``` + +Print all supported options: + +```shell +iriscli distribution delegator-distr-info --help +``` + +## Unique Flags + +There is no unique option. But it requires a argument: delegator address + +## Examples + +```shell +iriscli distribution delegation-distr-info +``` +Example response: +```json +[ + { + "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", + "val_operator_addr": "fva14a70gzu0v2w8dlfx462c9sldvja24qaz6vv4sg", + "del_pool_withdrawal_height": "10859" + }, + { + "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", + "val_operator_addr": "fva1ezzh0humhy3329xg4avhcjtay985nll0hpyhf4", + "del_pool_withdrawal_height": "4044" + } +] +``` \ No newline at end of file diff --git a/docs/cli-client/distribution/set-withdraw-address.md b/docs/cli-client/distribution/set-withdraw-address.md new file mode 100644 index 000000000..bc9b5ed4c --- /dev/null +++ b/docs/cli-client/distribution/set-withdraw-address.md @@ -0,0 +1,28 @@ +# iriscli distribution set-withdraw-addr + +## Description + +Set withdraw address of a delegator + +## Usage + +``` +iriscli distribution set-withdraw-addr [withdraw-addr] [flags] +``` + +Print all supported options: + +```shell +iriscli distribution set-withdraw-addr --help +``` + +## Unique Flags + +There is no unique option. But it requires a argument: new withdraw address + + +## Examples + +```shell +iriscli distribution set-withdraw-addr
--from --fee=0.004iris --chain-id= +``` diff --git a/docs/cli-client/distribution/validator-distr-info.md b/docs/cli-client/distribution/validator-distr-info.md new file mode 100644 index 000000000..486c4142a --- /dev/null +++ b/docs/cli-client/distribution/validator-distr-info.md @@ -0,0 +1,43 @@ +# iriscli distribution validator-distr-info + +## Description + +Query validator distribution information + +## Usage + +``` +iriscli distribution validator-distr-info [flags] +``` + +Print all supported options: + +```shell +iriscli distribution validator-distr-info --help +``` + +## Unique Flags + +There is no unique option. But it requires a argument: validator address + + +## Examples + +```shell +iriscli distribution validator-distr-info +``` +Example response: +```json +[ + { + "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", + "val_operator_addr": "fva14a70gzu0v2w8dlfx462c9sldvja24qaz6vv4sg", + "del_pool_withdrawal_height": "10859" + }, + { + "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", + "val_operator_addr": "fva1ezzh0humhy3329xg4avhcjtay985nll0hpyhf4", + "del_pool_withdrawal_height": "4044" + } +] +``` \ No newline at end of file diff --git a/docs/cli-client/distribution/withdraw-address.md b/docs/cli-client/distribution/withdraw-address.md new file mode 100644 index 000000000..be1c4fcb6 --- /dev/null +++ b/docs/cli-client/distribution/withdraw-address.md @@ -0,0 +1,33 @@ +# iriscli distribution withdraw-address + +## Description + +Query withdraw address of a delegator + +## Usage + +``` +iriscli distribution withdraw-address [delegator address] [flags] +``` + +Print all supported options: + +```shell +iriscli distribution withdraw-address --help +``` + +## Unique Flags + +There is no unique option. But it requires a argument: delegator address + + +## Examples + +```shell +iriscli distribution withdraw-address +``` +Example response: +```text +faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j +``` +If the given delegator didn't specify other withdraw address, the query result will be empty. \ No newline at end of file diff --git a/docs/cli-client/distribution/withdraw-rewards.md b/docs/cli-client/distribution/withdraw-rewards.md new file mode 100644 index 000000000..c6e44f78f --- /dev/null +++ b/docs/cli-client/distribution/withdraw-rewards.md @@ -0,0 +1,41 @@ +# iriscli distribution withdraw-rewards + +## Description + +Withdraw rewards + +## Usage + +``` +iriscli distribution withdraw-rewards [flags] +``` + +Print all supported options: + +```shell +iriscli distribution withdraw-rewards --help +``` + +## Unique Flags + +| Name, shorthand | type | Required | Default | Description | +| --------------------- | ----- | -------- | -------- | ------------------------------------------------------------------- | +| --only-from-validator | string | false | "" | only withdraw from this validator address (in bech) | +| --is-validator | bool | false | false | Also withdraw validator's commission | + +Keep in mind, don't specify the above options both. + +## Examples + +1. Only withdraw the delegation reward from a given validator + ``` + iriscli distribution withdraw-rewards --only-from-validator fva134mhjjyyc7mehvaay0f3d4hj8qx3ee3w3eq5nq --from mykey --fee=0.004iris --chain-id=irishub-test + ``` +2. Withdraw all delegation reward of a delegator + ``` + iriscli distribution withdraw-rewards --from mykey --fee=0.004iris --chain-id=irishub-test + ``` +3. If the delegator is a onwer of a validator, withdraw all delegation reward and validator reward: + ``` + iriscli distribution withdraw-rewards --is-validator=true --from mykey --fee=0.004iris --chain-id=irishub-test + ``` \ No newline at end of file diff --git a/docs/cli-client/stake/README.md b/docs/cli-client/stake/README.md index 1ae4daf48..cd6b52e91 100644 --- a/docs/cli-client/stake/README.md +++ b/docs/cli-client/stake/README.md @@ -2,12 +2,17 @@ ## Description -Stake allows you to execute stake and validation subcommands +Stake module provides a set of subcommands to query staking state and send staking transactions. ## Usage ```shell -iriscli stake [command] +iriscli stake [subcommand] +``` + +Print all supported subcommands and flags: +```shell +iriscli stake --help ``` ## Available Commands @@ -34,11 +39,3 @@ iriscli stake [command] | [redelegate](redelegate.md) | Redelegate illiquid tokens from one validator to another | | [unjail](unjail.md) | Unjail validator previously jailed for downtime | -## Flags - -| Name, shorthand | Default | Description | Required | -| --------------- | ------- | --------------- | -------- | -| --help, -h | | help for stake | | - - diff --git a/docs/cli-client/stake/create-validator.md b/docs/cli-client/stake/create-validator.md index 3816421a1..c9d92ff88 100644 --- a/docs/cli-client/stake/create-validator.md +++ b/docs/cli-client/stake/create-validator.md @@ -2,7 +2,7 @@ ## Description -Create new validator initialized with a self-delegation to it +Create new validator initialized with a self-delegation on it ## Usage @@ -10,49 +10,34 @@ Create new validator initialized with a self-delegation to it iriscli stake create-validator [flags] ``` -## Flags - -| Name, shorthand | Default | Description | Required | -| ---------------------------- | --------------------- | ------------------------------------------------------------------- | -------- | -| --account-number | | [int] AccountNumber number to sign the tx | | -| --address-delegator | | [string] Bech address of the delegator | | -| --amount | | [string] Amount of coins to bond | Yes | -| --async | | Broadcast transactions asynchronously | | -| --chain-id | | [string] Chain ID of tendermint node | Yes | -| --commission-max-change-rate | | [string] The maximum commission change rate percentage (per day) | Yes | -| --commission-max-rate | | [string] The maximum commission rate percentage | Yes | -| --commission-rate | | [string] The initial commission rate percentage | Yes | -| --details | | [string] Optional details | | -| --dry-run | | Ignore the --gas flag and perform a simulation of a transaction, but don't broadcast it | | -| --fee | | [string] Fee to pay along with transaction | Yes | -| --from | | [string] Name of private key with which to sign | Yes | -| --from-addr | | [string] Specify from address in generate-only mode | | -| --gas | 200000 | [string] Gas limit to set per-transaction; set to "simulate" to calculate required gas automatically | | -| --gas-adjustment | 1 | [float] Adjustment factor to be multiplied against the estimate returned by the tx simulation; if the gas limit is set manually this flag is ignor | | -| --generate-only | | Build an unsigned transaction and write it to STDOUT | | -| --genesis-format | | Export the transaction in gen-tx format; it implies --generate-only | | -| --help, -h | | Help for create-validator | | -| --identity | | [string] Optional identity signature (ex. UPort or Keybase) | | -| --indent | | Add indent to JSON response | | -| --ip | | [string] Node's public IP. It takes effect only when used in combination with --genesis-format | | -| --json | | Return output in json format | | -| --ledger | | Use a connected Ledger device | | -| --memo | | [string] Memo to send along with transaction | | -| --moniker | | [string] Validator name | | -| --node | tcp://localhost:26657 | [string] \:\ to tendermint rpc interface for this chain | | -| --node-id | | [string] Node's ID | | -| --print-response | | Return tx response (only works with async = false) | | -| --pubkey | | [string] Go-Amino encoded hex PubKey of the validator. For Ed25519 the go-amino prepend hex is 1624de6220 | Yes | -| --sequence | | [int] Sequence number to sign the tx | | -| --trust-node | true | Don't verify proofs for responses | | -| --website | | [string] Optional website | | +Print help messages: +```shell +iriscli stake create-validator --help +``` + +## Unique Flags + +| Name, shorthand | type | Required | Default | Description | +| ---------------------------- | ----- | -------- | -------- | ------------------------------------------------------------------- | +| --address-delegator | string | true | "" | Bech address of the delegator | +| --amount | string | true | "" | Amount of coins to bond | +| --commission-max-change-rate | float | true | 0.0 | The maximum commission change rate percentage (per day)| +| --commission-max-rate | float | true | 0.0 | The maximum commission rate percentage | +| --commission-rate | float | true | 0.0 | The initial commission rate percentage | +| --details | string | false | "" | Optional details | +| --genesis-format | bool | false | false | Export the transaction in gen-tx format; it implies --generate-only | +| --identity | string | false | "" | Optional identity signature (ex. UPort or Keybase) | +| --ip | string | false | "" | Node's public IP. It takes effect only when used in combination with | +| --moniker | string | true | "" | Validator name | +| --pubkey | string | true | "" | Go-Amino encoded hex PubKey of the validator. For Ed25519 the go-amino prepend hex is 1624de6220 | +| --website | string | false | "" | Optional website | ## Examples ### Create new validator ```shell -iriscli stake create-validator --chain-id=ChainID --from=KeyName --fee=Fee --pubkey=ValidatorPublicKey --commission-max-change-rate=CommissionMaxChangeRate --commission-max-rate=CommissionMaxRate --commission-rate=CommissionRate --amount=Coins +iriscli stake create-validator --chain-id= --from= --fee=0.004iris --pubkey= --commission-max-change-rate=0.01 --commission-max-rate=0.2 --commission-rate=0.1 --amount=100iris --moniker= ``` After that, you're done with creating a new validator. diff --git a/docs/cli-client/stake/delegate.md b/docs/cli-client/stake/delegate.md index 5c3c7b316..b9e315591 100644 --- a/docs/cli-client/stake/delegate.md +++ b/docs/cli-client/stake/delegate.md @@ -10,31 +10,17 @@ Delegate liquid tokens to an validator iriscli stake delegate [flags] ``` -## Flags - -| Name, shorthand | Default | Description | Required | -| ---------------------------- | --------------------- | ------------------------------------------------------------------- | -------- | -| --account-number | | [int] AccountNumber number to sign the tx | | -| --address-validator | | [string] Bech address of the validator | Yes | -| --amount | | [string] Amount of coins to bond | Yes | -| --async | | broadcast transactions asynchronously | | -| --chain-id | | [string] Chain ID of tendermint node | Yes | -| --dry-run | | Ignore the --gas flag and perform a simulation of a transaction, but don't broadcast it | | -| --fee | | [string] Fee to pay along with transaction | Yes | -| --from | | [string] Name of private key with which to sign | Yes | -| --from-addr | | [string] Specify from address in generate-only mode | | -| --gas | 200000 | [string] Gas limit to set per-transaction; set to "simulate" to calculate required gas automatically | | -| --gas-adjustment | 1 | [float] Adjustment factor to be multiplied against the estimate returned by the tx simulation; if the gas limit is set |manually this flag is ignored | | -| --generate-only | | Build an unsigned transaction and write it to STDOUT | | -| --help, -h | | Help for delegate | | -| --indent | | Add indent to JSON response | | -| --json | | Return output in json format | | -| --ledger | | Use a connected Ledger device | | -| --memo | | [string] Memo to send along with transaction | | -| --node | tcp://localhost:26657 | [string] \:\ to tendermint rpc interface for this chain | | -| --print-response | | return tx response (only works with async = false) | | -| --sequence int | | Sequence number to sign the tx | | -| --trust-node | true | Don't verify proofs for responses | | +Print help messages: +```shell +iriscli stake delegate --help +``` + +## Unique Flags + +| Name, shorthand | type | Required | Default | Description | +| --------------------| ----- | -------- | -------- | ------------------------------------------------------------------- | +| --address-delegator | string | true | "" | Bech address of the delegator | +| --amount | string | true | "" | Amount of coins to bond | ## Examples diff --git a/docs/cli-client/stake/edit-validator.md b/docs/cli-client/stake/edit-validator.md index 36dc8c3ce..98debd321 100644 --- a/docs/cli-client/stake/edit-validator.md +++ b/docs/cli-client/stake/edit-validator.md @@ -2,60 +2,38 @@ ## Description -Edit existing validator account +Edit existing validator ## Usage ``` iriscli stake edit-validator [flags] ``` +Print help messages: +```shell +iriscli stake edit-validator --help +``` + +## Unique Flags -## Flags +| Name, shorthand | type | Required | Default | Description | +| --------------------| ----- | -------- | -------- | ------------------------------------------------------------------- | +| --commission-rate | string | float | 0.0 | Commission rate percentage | +| --moniker | string | false | "" | Validator name | +| --identity | string | false | "" | Optional identity signature (ex. UPort or Keybase) | +| --website | string | false | "" | Optional website | +| --details | string | false | "" | Optional details | -| Name, shorthand | Default | Description | Required | -| ---------------------------- | --------------------- | ------------------------------------------------------------------- | -------- | -| --account-number | | [int] AccountNumber number to sign the tx | | -| --address-delegator | | [string] Bech address of the delegator | | -| --amount | | [string] Amount of coins to bond | | -| --async | | Broadcast transactions asynchronously | | -| --chain-id | | [string] Chain ID of tendermint node | Yes | -| --commission-max-change-rate | | [string] The maximum commission change rate percentage (per day) | | -| --commission-max-rate | | [string] The maximum commission rate percentage | | -| --commission-rate | | [string] The initial commission rate percentage | | -| --details | | [string] Optional details | | -| --dry-run | | Ignore the --gas flag and perform a simulation of a transaction, but don't broadcast it | | -| --fee | | [string] Fee to pay along with transaction | Yes | -| --from | | [string] Name of private key with which to sign | Yes | -| --from-addr | | [string] Specify from address in generate-only mode | | -| --gas | 200000 | [string] Gas limit to set per-transaction; set to "simulate" to calculate required gas automatically | | -| --gas-adjustment | 1 | [float] Adjustment factor to be multiplied against the estimate returned by the tx simulation; if the gas limit is set manually this flag is ignor | | -| --generate-only | | Build an unsigned transaction and write it to STDOUT | | -| --genesis-format | | Export the transaction in gen-tx format; it implies --generate-only | | -| --help, -h | | Help for edit-validator | | -| --identity | | [string] Optional identity signature (ex. UPort or Keybase) | | -| --indent | | Add indent to JSON response | | -| --ip | | [string] Node's public IP. It takes effect only when used in combination with --genesis-format | | -| --json | | Return output in json format | | -| --ledger | | Use a connected Ledger device | | -| --memo | | [string] Memo to send along with transaction | | -| --moniker | | [string] Validator name | | -| --node | tcp://localhost:26657 | [string] \:\ to tendermint rpc interface for this chain | | -| --node-id | | [string] Node's ID | | -| --print-response | | Return tx response (only works with async = false) | | -| --pubkey | | [string] Go-Amino encoded hex PubKey of the validator. For Ed25519 the go-amino prepend hex is 1624de6220 | | -| --sequence | | [int] Sequence number to sign the tx | | -| --trust-node | true | Don't verify proofs for responses | | -| --website | | [string] Optional website | | ## Examples ### Edit existing validator account ```shell -iriscli stake edit-validator --from=KeyName --chain-id=ChainID --fee=Fee --memo=YourMemo +iriscli stake edit-validator --from= --chain-id= --fee=0.004iris --commission-rate=0.15 ``` -After that, you're done with editting a new validator. +After that, you're done with editing a new validator. ```txt Committed at block 2160 (tx hash: C48CABDA1183B5319003433EB1FDEBE5A626E00BD319F1A84D84B6247E9224D1, response: {Code:0 Data:[] Log:Msg 0: Info: GasWanted:200000 GasUsed:3540 Tags:[{Key:[97 99 116 105 111 110] Value:[101 100 105 116 45 118 97 108 105 100 97 116 111 114] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[100 101 115 116 105 110 97 116 105 111 110 45 118 97 108 105 100 97 116 111 114] Value:[102 118 97 49 53 103 114 118 51 120 103 51 101 107 120 104 57 120 114 102 55 57 122 100 48 119 48 55 55 107 114 103 118 53 120 102 54 100 54 116 104 100] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[109 111 110 105 107 101 114] Value:[117 98 117 110 116 117 49 56] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[105 100 101 110 116 105 116 121] Value:[] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[99 111 109 112 108 101 116 101 67 111 110 115 117 109 101 100 84 120 70 101 101 45 105 114 105 115 45 97 116 116 111] Value:[34 49 55 55 48 48 48 48 48 48 48 48 48 48 48 48 34] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}] Codespace: XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}) diff --git a/docs/cli-client/stake/redelegate.md b/docs/cli-client/stake/redelegate.md index a54d1e319..e211cec84 100644 --- a/docs/cli-client/stake/redelegate.md +++ b/docs/cli-client/stake/redelegate.md @@ -2,7 +2,7 @@ ## Description -Redelegate illiquid tokens from one validator to another +Redelegate transfer delegation from one validator to another one. ## Usage @@ -10,33 +10,22 @@ Redelegate illiquid tokens from one validator to another iriscli stake redelegate [flags] ``` -## Flags - -| Name, shorthand | Default | Description | Required | -| ---------------------------- | --------------------- | ------------------------------------------------------------------- | -------- | -| --account-number | | [int] AccountNumber number to sign the tx | | -| --address-validator-dest | | [string] Bech address of the destination validator | Yes | -| --address-validator-source | | [string] Bech address of the source validator | Yes | -| --async | | Broadcast transactions asynchronously | | -| --chain-id | | [string] Chain ID of tendermint node | Yes | -| --dry-run | | Ignore the --gas flag and perform a simulation of a transaction, but don't broadcast it || -| --fee | | [string] Fee to pay along with transaction | Yes | -| --from | | [string] Name of private key with which to sign | Yes | -| --from-addr | | [string] Specify from address in generate-only mode | | -| --gas | 200000 | [string] Gas limit to set per-transaction; set to "simulate" to calculate required gas automatically || -| --gas-adjustment | 1 | [float] Adjustment factor to be multiplied against the estimate returned by the tx simulation; if the gas limit is set manually this flag is ignored || -| --generate-only | | build an unsigned transaction and write it to STDOUT | | -| --help, -h | | help for redelegate | | -| --indent | | Add indent to JSON response | | -| --json | | return output in json format | | -| --ledger | | Use a connected Ledger device | | -| --memo | | [string] Memo to send along with transaction | | -| --node | tcp://localhost:26657 | [string] \:\ to tendermint rpc interface for this chain | | -| --print-response | | return tx response (only works with async = false) | | -| --sequence | | [int] Sequence number to sign the tx | | -| --shares-amount | | [string] Amount of source-shares to either unbond or redelegate as a positive integer or decimal || -| --shares-percent | | [string] Percent of source-shares to either unbond or redelegate as a positive integer or decimal >0 and <=1 || -| --trust-node | true | Don't verify proofs for responses | | +Print all help messages: + +```shell +iriscli stake redelegate --help +``` + +## Unique Flags + +| Name, shorthand | type | Required | Default | Description | +| -------------------------- | ----- | -------- | -------- | ------------------------------------------------------------------- | +| --address-validator-dest | string | true | "" | Bech address of the destination validator | +| --address-validator-source | string | true | "" | Bech address of the source validator | +| --shares-amount | float | false | 0.0 | Amount of source-shares to either unbond or redelegate as a positive integer or decimal | +| --shares-percent | float | false | 0.0 | Percent of source-shares to either unbond or redelegate as a positive integer or decimal >0 and <=1 | + +Users must specify the redeleagte amount. There two options can do this: `--shares-amount` or `--shares-percent`. Keep in mind, don't specify them both. ## Examples diff --git a/docs/cli-client/stake/unbond.md b/docs/cli-client/stake/unbond.md index bcea3aeb2..bc8ecdbc8 100644 --- a/docs/cli-client/stake/unbond.md +++ b/docs/cli-client/stake/unbond.md @@ -10,32 +10,21 @@ Unbond shares from a validator iriscli stake unbond [flags] ``` -## Flags - -| Name, shorthand | Default | Description | Required | -| --------------------- | --------------------- | ------------------------------------------------------------------------------------------------------------- | -------- | -| --account-number | | [int] AccountNumber number to sign the tx | | -| --address-validator | | [string] Bech address of the validator | Yes | -| --async | | Broadcast transactions asynchronously | | -| --chain-id | | [string] Chain ID of tendermint node | Yes | -| --dry-run | | Ignore the --gas flag and perform a simulation of a transaction, but don't broadcast it | | -| --fee | | [string] Fee to pay along with transaction | Yes | -| --from | | [string] Name of private key with which to sign | Yes | -| --from-addr | | [string] Specify from address in generate-only mode | | -| --gas | 200000 | [string] Gas limit to set per-transaction; set to "simulate" to calculate required gas automatically | | -| --gas-adjustment | 1 | [float] Adjustment factor to be multiplied against the estimate returned by the tx simulation; if the gas limit is set manually this flag is ignored | | -| --generate-only | | build an unsigned transaction and write it to STDOUT | | -| --help, -h | | help for unbond | | -| --indent | | Add indent to JSON response | | -| --json | | Return output in json format | | -| --ledger | | Use a connected Ledger device | | -| --memo | | [string] Memo to send along with transaction | | -| --node | tcp://localhost:26657 | [string] \:\ to tendermint rpc interface for this chain | | -| --print-response | | Return tx response (only works with async = false) | | -| --sequence | | [int] Sequence number to sign the tx | | -| --shares-amount | | [string] Amount of source-shares to either unbond or redelegate as a positive integer or decimal | | -| --shares-percent | | [string] Percent of source-shares to either unbond or redelegate as a positive integer or decimal >0 and <=1 | | -| --trust-node | true | Don't verify proofs for responses | | +Print all help messages: + +```shell +iriscli stake unbond --help +``` + +## Unique Flags + +| Name, shorthand | type | Required | Default | Description | +| --------------------| ----- | -------- | -------- | ------------------------------------------------------------------- | +| --address-delegator | string | true | "" | Bech address of the delegator | +| --shares-amount | float | false | 0.0 | Amount of source-shares to either unbond or redelegate as a positive integer or decimal | +| --shares-percent | float | false | 0.0 | Percent of source-shares to either unbond or redelegate as a positive integer or decimal >0 and <=1 | + +Users must specify the unbond amount. There two options can do this: `--shares-amount` or `--shares-percent`. Keep in mind, don't specify them both. ## Examples diff --git a/docs/cli-client/stake/unjail.md b/docs/cli-client/stake/unjail.md index 566cbe72e..74a582207 100644 --- a/docs/cli-client/stake/unjail.md +++ b/docs/cli-client/stake/unjail.md @@ -7,43 +7,25 @@ Unjail validator previously jailed for downtime ## Usage ``` -iriscli stake redelegate [flags] +iriscli stake unjail [flags] ``` -## Flags - -| Name, shorthand | Default | Description | Required | -| ---------------------------- | --------------------- | ------------------------------------------------------------------- | -------- | -| --account-number | | [int] AccountNumber number to sign the tx | | -| --address-validator-dest | | [string] Bech address of the destination validator | | -| --address-validator-source | | [string] Bech address of the source validator | | -| --async | | Broadcast transactions asynchronously | | -| --chain-id | | [string] Chain ID of tendermint node | Yes | -| --dry-run | | Ignore the --gas flag and perform a simulation of a transaction, but don't broadcast it || -| --fee | | [string] Fee to pay along with transaction | Yes | -| --from | | [string] Name of private key with which to sign | Yes | -| --from-addr | | [string] Specify from address in generate-only mode | | -| --gas | 200000 | [string] Gas limit to set per-transaction; set to "simulate" to calculate required gas automatically || -| --gas-adjustment | 1 | [float] Adjustment factor to be multiplied against the estimate returned by the tx simulation; if the gas limit is set manually this flag is ignored || -| --generate-only | | build an unsigned transaction and write it to STDOUT | | -| --help, -h | | help for unjail | | -| --indent | | Add indent to JSON response | | -| --json | | return output in json format | | -| --ledger | | Use a connected Ledger device | | -| --memo | | [string] Memo to send along with transaction | | -| --node | tcp://localhost:26657 | [string] \:\ to tendermint rpc interface for this chain | | -| --print-response | | return tx response (only works with async = false) | | -| --sequence int | | Sequence number to sign the tx | | -| --shares-amount | | [string] Amount of source-shares to either unbond or redelegate as a positive integer or decimal || -| --shares-percent | | [string] Percent of source-shares to either unbond or redelegate as a positive integer or decimal >0 and <=1 || -| --trust-node | true | Don't verify proofs for responses | | +Print all help messages: + +```shell +iriscli stake unjail --help +``` + +## Unique Flags + +There is no unique flags. ## Examples ### Unjail validator previously jailed for downtime ```shell -iriscli stake unjail --from=KeyName --fee=Fee --chain-id=ChainID +iriscli stake unjail --from= --fee=0.004iris --chain-id= ``` After that, you're done with unjailing specified validator. From 008f43a1f3bac8283b41f365f1082e3f39127cfe Mon Sep 17 00:00:00 2001 From: HaoyangLiu Date: Sat, 17 Nov 2018 14:25:21 +0800 Subject: [PATCH 2/5] Refactor Chinese docs for distribution --- docs/zh/README.md | 58 ++++++++- docs/zh/cli-client/distribution/README.md | 111 ++++-------------- .../distribution/delegation-distr-info.md | 38 ++++++ .../distribution/delegator-distr-info.md | 42 +++++++ .../distribution/set-withdraw-address.md | 28 +++++ .../distribution/validator-distr-info.md | 43 +++++++ .../distribution/withdraw-address.md | 33 ++++++ .../distribution/withdraw-rewards.md | 41 +++++++ 8 files changed, 299 insertions(+), 95 deletions(-) create mode 100644 docs/zh/cli-client/distribution/delegation-distr-info.md create mode 100644 docs/zh/cli-client/distribution/delegator-distr-info.md create mode 100644 docs/zh/cli-client/distribution/set-withdraw-address.md create mode 100644 docs/zh/cli-client/distribution/validator-distr-info.md create mode 100644 docs/zh/cli-client/distribution/withdraw-address.md create mode 100644 docs/zh/cli-client/distribution/withdraw-rewards.md diff --git a/docs/zh/README.md b/docs/zh/README.md index 0d04c7b6c..c4586a191 100644 --- a/docs/zh/README.md +++ b/docs/zh/README.md @@ -1,5 +1,55 @@ -# IRISnet文档目录 -![irisnet](../pics/iris.jpg) +# 命令行客户端 -IRIS网络是上海边界智能和Tendermint团队合作打造的跨链区块链网络,将是Cosmos网络生态中的第一个区域性枢纽(Hub),并专注于为分布式商业应用提供基础 设施和协议。 -IRISnet将面向服务的基础设施融入到Cosmos网络中,支持对包括公链、联盟链以及 现有传统商业系统的集成从而实现互联互通。通过对Cosmos网络的跨链协议进行创新 扩展,IRISnet允许数据及复杂计算跨异构网络被调用。就像忠实地在人间和天堂传递 信息的希腊彩虹女神 Iris, IRISnet的目标是成为链接数字经济和实体经济,支持构建复 杂分布式商业应用的下一代公链。 +## 查询命令的flags + +| Name, shorthand | type | Required | Default Value | Description | +| --------------- | ---- | -------- | --------------------- | -------------------------------------------------------------------- | +| --chain-id | string | false | "" | Tendermint节点的Chain ID | +| --height | int | false | 0 | 查询某个高度的区块链数据,如果是0,这返回最新的区块链数据 | +| --help, -h | string | false | | 打印帮助信息 | +| --indent | bool | false | false | 格式化json字符串| +| --ledger | bool | false | false | 是否使用硬件钱包 | +| --node | string | false | tcp://localhost:26657 | tendermint节点的rpc地址| +| --trust-node | bool | false | true | 是否信任全节点返回的数据,如果不信任,客户端会验证查询结果的正确性 | + +每个区块链状态查询命令都包含上表中的flags,同时不同查询命令还可能会有自己独有的flags。 + +## 发送交易命令的flags + +| Name, shorthand | type | Required | Default | Description | +| -----------------| ----- | -------- | --------------------- | ------------------------------------------------------------------- | +| --account-number | int | false | 0 | 发起交易的账户的编号 | +| --async | bool | false | false | 是否异步广播交易 | +| --chain-id | string | true | "" | Tendermint节点的`Chain ID` | +| --dry-run | bool | false | false | 模拟执行交易,并返回消耗的`gas`。`--gas`指定的值会被忽略 | +| --fee | string | true | "" | 交易费 | +| --from | string | false | "" | 发送交易的账户名称 | +| --from-addr | string | false | "" | 签名地址,在`generate-only`为`true`的情况下有效 | +| --gas | int | false | 200000 | 交易的gas上限; 设置为"simulate"将自动计算相应的阈值 | +| --gas-adjustment | int | false | 1 | gas调整因子,这个值降乘以模拟执行消耗的`gas`,计算的结果返回给用户; 如果`--gas`的值不是`simulate`,这个标志将被忽略 | +| --generate-only | bool | false | false | 是否仅仅构建一个未签名的交易便返回 | +| --help, -h | string | false | | 打印帮助信息 | +| --indent | bool | false | false | 格式化json字符串 | +| --json | string | false | false | 指定返回结果的格式,`json`或者`text` | +| --ledger | bool | false | false | 是否使用硬件钱包| +| --memo | string | false | "" | 指定交易的memo字段 | +| --node | string | false | tcp://localhost:26657 | tendermint节点的rpc地址 | +| --print-response | bool | false | false | 是否打印交易返回结果,仅在`async`为true的情况下有效| +| --sequence int | int | false | 0 | 发起交易的账户的sequence | +| --trust-node | bool | false | true | 是否信任全节点返回的数据,如果不信任,客户端会验证查询结果的正确性 | + +每个发送交易的命令都包含上表中的flags,同时不同交易的命令还可能会有自己独有的flags。 + +## Command list + +1. [bank command](./bank/README.md) +2. [distribution command](./distribution/README.md) +3. [gov command](./gov/README.md) +4. [keys command](./keys/README.md) +5. [lcd command](./lcd/README.md) +6. [record command](./record/README.md) +7. [service command](./service/README.md) +8. [stake command](./stake/README.md) +9. [status command](./status/README.md) +10. [tendermint command](./tendermint/README.md) +11. [upgrade command](./upgrade/README.md) diff --git a/docs/zh/cli-client/distribution/README.md b/docs/zh/cli-client/distribution/README.md index b82ff74ed..1b9fbc879 100644 --- a/docs/zh/cli-client/distribution/README.md +++ b/docs/zh/cli-client/distribution/README.md @@ -1,99 +1,28 @@ -# 介绍 +# iriscli distribution -这里主要介绍distribution模块对于的命令行接口。 +## 介绍 -# 查询接口 +这里主要介绍distribution模块提供的命令行接口 -在默认情况下,所以查询命令处于信任模式,也就是在查询的时候不要求全节点返回查询结果对于的proof,并且即使全节点返回proof也不会对其进行验证。如果用户不信任所连接的全节点,可以通过在查询命令后天就`--trust-node=false`来使能非信任模式。 +## 用法 -1. 查询撤回地址 +```shell +iriscli distribution [subcommand] +``` - 示例命令: - ```bash - iriscli distribution withdraw-address faa1vm068fnjx28zv7k9kd9j85wrwhjn8vfsxfmcrz - ``` - 如果委托人没有指定过撤回地址,那么查询结果为空。 +打印所以子命令和参数 -2. 查询委托(delegation)的收益分配记录 +```shell +iriscli distribution --help +``` - 示例命令: - ```bash - iriscli distribution delegation-distr-info --address-delegator=faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j \ - --address-validator=fva1ezzh0humhy3329xg4avhcjtay985nll0hpyhf4 - ``` - 示例查询结果: - ```json - { - "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", - "val_operator_addr": "fva1ezzh0humhy3329xg4avhcjtay985nll0hpyhf4", - "del_pool_withdrawal_height": "4044" - } - ``` - 从这个查询结果可知,这个委托是在4044高度创建的,或者在4044高度发起过撤回交易。 +## 子命令 -2. 查询委托人所有的委托(delegation)的收益分配记录 - - 示例命令: - ```bash - iriscli distribution delegator-distr-info faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j - ``` - 示例查询结果: - ```json - [ - { - "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", - "val_operator_addr": "fva14a70gzu0v2w8dlfx462c9sldvja24qaz6vv4sg", - "del_pool_withdrawal_height": "10859" - }, - { - "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", - "val_operator_addr": "fva1ezzh0humhy3329xg4avhcjtay985nll0hpyhf4", - "del_pool_withdrawal_height": "4044" - } - ] - ``` - -4. 查询验证人收益分配记录 - - 示例命令: - ```bash - iriscli distribution delegator-distr-info faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j - ``` - 示例查询结果: - ```json - { - "operator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", - "fee_pool_withdrawal_height": "416", - "del_accum": { - "update_height": "416", - "accum": "10000.0000000000" - }, - "del_pool": "10.1300000000iris", - "val_commission": "1.2345000000iris" - } - ``` - 从这个查询结果可知,这个委托是在4044高度创建的,或者在4044高度发起过撤回交易。 - -# 发交易接口 - -1. 设置收益收款地址 - - 示例命令: - ```bash - iriscli distribution set-withdraw-addr faa1syva9fvh8m6dc6wjnjedah64mmpq7rwwz6nj0k --from mykey --fee=0.004iris --chain-id=irishub-test - ``` - -2. withdraw rewards - - 1. 仅撤回某一个委托产生的收益 - ```bash - iriscli distribution withdraw-rewards --only-from-validator fva134mhjjyyc7mehvaay0f3d4hj8qx3ee3w3eq5nq --from mykey --fee=0.004iris --chain-id=irishub-test - ``` - 2. 仅撤回某所有委托产生的收益 - ```bash - iriscli distribution withdraw-rewards --from mykey --fee=0.004iris --chain-id=irishub-test - ``` - 3. 仅撤回某所有委托产生的收益和验证人的佣金收益 - ```bash - iriscli distribution withdraw-rewards --is-validator=true --from mykey --fee=0.004iris --chain-id=irishub-test - ``` \ No newline at end of file +| 名称 | 功能 | +| --------------------------------| --------------------------------------------------------------| +| [delegation-distr-info](delegation-distr-info.md) | 查询委托(delegation)的收益分配记录 | +| [delegator-distr-info](delegator-distr-info.md) | 查询委托人所有的委托(delegation)的收益分配记录 | +| [validator-distr-info](validator-distr-info.md) | 查询验证人收益分配记录 | +| [withdraw-address](withdraw-address.md) | 查询收益取回地址 | +| [set-withdraw-address](set-withdraw-address.md) | 设置收益取回地址 | +| [withdraw-rewards](withdraw-rewards.md) | 发起取回收益的交易 | diff --git a/docs/zh/cli-client/distribution/delegation-distr-info.md b/docs/zh/cli-client/distribution/delegation-distr-info.md new file mode 100644 index 000000000..1e7f3801b --- /dev/null +++ b/docs/zh/cli-client/distribution/delegation-distr-info.md @@ -0,0 +1,38 @@ +# iriscli distribution delegation-distr-info + +## 介绍 + +查询某个委托的收益分配信息 + +## 用法 + +``` +iriscli distribution delegation-distr-info [flags] +``` + +打印帮助信息 + +```shell +iriscli distribution delegation-distr-info --help +``` + +## 特有的flags + +| 名称 | 类型 | 是否必填 | 默认值 | 功能描述 | +| --------------------| ----- | -------- | -------- | -------------- | +| --address-validator | string | true | "" | 验证人bech地址 | +| --address-delegator | string | true | "" | 委托人bech地址 | + +## 示例 + +```shell +iriscli distribution delegation-distr-info --address-delegator= --address-validator= +``` +执行结果示例 +```json +{ + "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", + "val_operator_addr": "fva1ezzh0humhy3329xg4avhcjtay985nll0hpyhf4", + "del_pool_withdrawal_height": "4044" +} +``` \ No newline at end of file diff --git a/docs/zh/cli-client/distribution/delegator-distr-info.md b/docs/zh/cli-client/distribution/delegator-distr-info.md new file mode 100644 index 000000000..45d2f9255 --- /dev/null +++ b/docs/zh/cli-client/distribution/delegator-distr-info.md @@ -0,0 +1,42 @@ +# iriscli distribution delegator-distr-info + +## 介绍 + +查询委托人全部委托的收益分配信息 + +## 用法 + +``` +iriscli distribution delegator-distr-info [flags] +``` + +打印帮助信息 + +```shell +iriscli distribution delegator-distr-info --help +``` + +## 特有的flags + +这个命令没有特有的flag,它有一个输入参数:delegator的地址 + +## 示例 + +```shell +iriscli distribution delegation-distr-info +``` +执行结果示例 +```json +[ + { + "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", + "val_operator_addr": "fva14a70gzu0v2w8dlfx462c9sldvja24qaz6vv4sg", + "del_pool_withdrawal_height": "10859" + }, + { + "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", + "val_operator_addr": "fva1ezzh0humhy3329xg4avhcjtay985nll0hpyhf4", + "del_pool_withdrawal_height": "4044" + } +] +``` \ No newline at end of file diff --git a/docs/zh/cli-client/distribution/set-withdraw-address.md b/docs/zh/cli-client/distribution/set-withdraw-address.md new file mode 100644 index 000000000..17fe2204c --- /dev/null +++ b/docs/zh/cli-client/distribution/set-withdraw-address.md @@ -0,0 +1,28 @@ +# iriscli distribution set-withdraw-addr + +## 介绍 + +设置取回收益时的收款地址 + +## 用法 + +``` +iriscli distribution set-withdraw-addr [withdraw-addr] [flags] +``` + +打印帮助信息: + +``` +iriscli distribution set-withdraw-addr --help +``` + +## 特有的flags + +这个命令没有特有的flag,它有一个输入参数:收款地址 + + +## 示例 + +``` +iriscli distribution set-withdraw-addr
--from --fee=0.004iris --chain-id= +``` diff --git a/docs/zh/cli-client/distribution/validator-distr-info.md b/docs/zh/cli-client/distribution/validator-distr-info.md new file mode 100644 index 000000000..21205b0db --- /dev/null +++ b/docs/zh/cli-client/distribution/validator-distr-info.md @@ -0,0 +1,43 @@ +# iriscli distribution validator-distr-info + +## 介绍 + +查询验证人的收益分配信息 + +## 用法 + +``` +iriscli distribution validator-distr-info [flags] +``` + +打印帮助信息: + +``` +iriscli distribution validator-distr-info --help +``` + +## 特有的flags + +这个命令没有特有的flag,它有一个输入参数:验证人地址 + + +## 示例 + +``` +iriscli distribution validator-distr-info +``` +执行结果示例 +```json +[ + { + "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", + "val_operator_addr": "fva14a70gzu0v2w8dlfx462c9sldvja24qaz6vv4sg", + "del_pool_withdrawal_height": "10859" + }, + { + "delegator_addr": "faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j", + "val_operator_addr": "fva1ezzh0humhy3329xg4avhcjtay985nll0hpyhf4", + "del_pool_withdrawal_height": "4044" + } +] +``` \ No newline at end of file diff --git a/docs/zh/cli-client/distribution/withdraw-address.md b/docs/zh/cli-client/distribution/withdraw-address.md new file mode 100644 index 000000000..c7e6607b0 --- /dev/null +++ b/docs/zh/cli-client/distribution/withdraw-address.md @@ -0,0 +1,33 @@ +# iriscli distribution withdraw-address + +## 介绍 + +查收取回收益时的收款地址 + +## 用法 + +``` +iriscli distribution withdraw-address [delegator address] [flags] +``` + +打印帮助信息: + +``` +iriscli distribution withdraw-address --help +``` + +## 特有的flags + +这个命令没有特有的flag,它有一个输入参数:委托人地址 + + +## 示例 + +``` +iriscli distribution withdraw-address +``` +执行结果示例 +``` +faa1ezzh0humhy3329xg4avhcjtay985nll0zswc5j +``` +If the given delegator didn't specify other withdraw address, the query result will be empty. \ No newline at end of file diff --git a/docs/zh/cli-client/distribution/withdraw-rewards.md b/docs/zh/cli-client/distribution/withdraw-rewards.md new file mode 100644 index 000000000..791aef94b --- /dev/null +++ b/docs/zh/cli-client/distribution/withdraw-rewards.md @@ -0,0 +1,41 @@ +# iriscli distribution withdraw-rewards + +## 介绍 + +取回收益 + +## 用法 + +``` +iriscli distribution withdraw-rewards [flags] +``` + +打印帮助信息: + +``` +iriscli distribution withdraw-rewards --help +``` + +## 特有的flags + +| Name, shorthand | type | Required | Default | Description | +| --------------------- | ----- | -------- | -------- | ------------------------------------------------------------------- | +| --only-from-validator | string | false | "" | only withdraw from this validator address (in bech) | +| --is-validator | bool | false | false | Also withdraw validator's commission | + +不能同时使用两个flags。 + +## 示例 + +1. 仅取回某一个委托产生的收益 + ``` + iriscli distribution withdraw-rewards --only-from-validator fva134mhjjyyc7mehvaay0f3d4hj8qx3ee3w3eq5nq --from mykey --fee=0.004iris --chain-id=irishub-test + ``` +2. 取回所有委托产生的收益,不包含验证人的佣金收益: + ``` + iriscli distribution withdraw-rewards --from mykey --fee=0.004iris --chain-id=irishub-test + ``` +3. 取回所有委托产生的收益以及验证人的佣金收益: + ``` + iriscli distribution withdraw-rewards --is-validator=true --from mykey --fee=0.004iris --chain-id=irishub-test + ``` \ No newline at end of file From f0ddfe381fb4cdae1043a4a76e9e97c51f88e84a Mon Sep 17 00:00:00 2001 From: HaoyangLiu Date: Sat, 17 Nov 2018 15:21:28 +0800 Subject: [PATCH 3/5] Reactor Chinese docs for stake --- docs/cli-client/stake/README.md | 2 +- docs/cli-client/stake/create-validator.md | 9 +-- docs/cli-client/stake/delegate.md | 22 +----- docs/cli-client/stake/edit-validator.md | 21 +----- docs/cli-client/stake/redelegate.md | 22 +----- docs/cli-client/stake/unbond.md | 24 +----- docs/cli-client/stake/unjail.md | 5 +- docs/zh/README.md | 58 +-------------- docs/zh/cli-client/README.md | 56 +++++++++++++- .../distribution/withdraw-rewards.md | 6 +- docs/zh/cli-client/stake/README.md | 66 ++++++++--------- docs/zh/cli-client/stake/create-validator.md | 74 +++++++------------ docs/zh/cli-client/stake/delegate.md | 62 ++++------------ docs/zh/cli-client/stake/edit-validator.md | 71 ++++-------------- docs/zh/cli-client/stake/redelegate.md | 71 ++++++------------ docs/zh/cli-client/stake/unbond.md | 65 +++++----------- docs/zh/cli-client/stake/unjail.md | 50 ++++--------- 17 files changed, 222 insertions(+), 462 deletions(-) diff --git a/docs/cli-client/stake/README.md b/docs/cli-client/stake/README.md index cd6b52e91..291e8a1e8 100644 --- a/docs/cli-client/stake/README.md +++ b/docs/cli-client/stake/README.md @@ -1,6 +1,6 @@ # iriscli stake -## Description +## Introduction Stake module provides a set of subcommands to query staking state and send staking transactions. diff --git a/docs/cli-client/stake/create-validator.md b/docs/cli-client/stake/create-validator.md index c9d92ff88..22f6b9053 100644 --- a/docs/cli-client/stake/create-validator.md +++ b/docs/cli-client/stake/create-validator.md @@ -1,8 +1,8 @@ # iriscli stake create-validator -## Description +## Introduction -Create new validator initialized with a self-delegation on it +Send transaction to apply to be validator and delegate a certain amount tokens on it ## Usage @@ -19,7 +19,6 @@ iriscli stake create-validator --help | Name, shorthand | type | Required | Default | Description | | ---------------------------- | ----- | -------- | -------- | ------------------------------------------------------------------- | -| --address-delegator | string | true | "" | Bech address of the delegator | | --amount | string | true | "" | Amount of coins to bond | | --commission-max-change-rate | float | true | 0.0 | The maximum commission change rate percentage (per day)| | --commission-max-rate | float | true | 0.0 | The maximum commission rate percentage | @@ -34,11 +33,7 @@ iriscli stake create-validator --help ## Examples -### Create new validator - ```shell iriscli stake create-validator --chain-id= --from= --fee=0.004iris --pubkey= --commission-max-change-rate=0.01 --commission-max-rate=0.2 --commission-rate=0.1 --amount=100iris --moniker= ``` -After that, you're done with creating a new validator. - diff --git a/docs/cli-client/stake/delegate.md b/docs/cli-client/stake/delegate.md index b9e315591..c10e56f78 100644 --- a/docs/cli-client/stake/delegate.md +++ b/docs/cli-client/stake/delegate.md @@ -1,8 +1,8 @@ # iriscli stake delegate -## Description +## Introduction -Delegate liquid tokens to an validator +Delegate tokens to a validator ## Usage @@ -24,22 +24,6 @@ iriscli stake delegate --help ## Examples -### Delegate liquid tokens to an validator - ```shell -iriscli stake delegate --chain-id=ChainID --from=KeyName --fee=Fee --amount=CoinstoBond --address-validator=ValidatorOwnerAddress -``` - -After that, you're done with delegating liquid tokens to specified validator. - -```txt -Committed at block 2352 (tx hash: 2069F0453619637EE67EFB0CFC53713AF28A0BB89137DEB4574D8B13E723999B, response: {Code:0 Data:[] Log:Msg 0: Info: GasWanted:200000 GasUsed:15993 Tags:[{Key:[97 99 116 105 111 110] Value:[100 101 108 101 103 97 116 101] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[100 101 108 101 103 97 116 111 114] Value:[102 97 97 49 51 108 99 119 110 120 112 121 110 50 101 97 51 115 107 122 109 101 107 54 52 118 118 110 112 57 55 106 115 107 56 113 109 104 108 54 118 120] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[100 101 115 116 105 110 97 116 105 111 110 45 118 97 108 105 100 97 116 111 114] Value:[102 118 97 49 53 103 114 118 51 120 103 51 101 107 120 104 57 120 114 102 55 57 122 100 48 119 48 55 55 107 114 103 118 53 120 102 54 100 54 116 104 100] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[99 111 109 112 108 101 116 101 67 111 110 115 117 109 101 100 84 120 70 101 101 45 105 114 105 115 45 97 116 116 111] Value:[34 55 57 57 54 53 48 48 48 48 48 48 48 48 48 48 48 34] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}] Codespace: XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}) -{ - "tags": { - "action": "delegate", - "completeConsumedTxFee-iris-atto": "\"7996500000000000\"", - "delegator": "faa13lcwnxpyn2ea3skzmek64vvnp97jsk8qmhl6vx", - "destination-validator": "fva15grv3xg3ekxh9xrf79zd0w077krgv5xf6d6thd" - } - } +iriscli stake delegate --chain-id= --from= --fee=0.004iris --amount=100iris --address-validator= ``` diff --git a/docs/cli-client/stake/edit-validator.md b/docs/cli-client/stake/edit-validator.md index 98debd321..3b7c1812e 100644 --- a/docs/cli-client/stake/edit-validator.md +++ b/docs/cli-client/stake/edit-validator.md @@ -1,8 +1,8 @@ # iriscli stake edit-validator -## Description +## Introduction -Edit existing validator +Edit existing validator, such as commission rate, name and other description message. ## Usage @@ -27,23 +27,6 @@ iriscli stake edit-validator --help ## Examples -### Edit existing validator account - ```shell iriscli stake edit-validator --from= --chain-id= --fee=0.004iris --commission-rate=0.15 ``` - -After that, you're done with editing a new validator. - -```txt -Committed at block 2160 (tx hash: C48CABDA1183B5319003433EB1FDEBE5A626E00BD319F1A84D84B6247E9224D1, response: {Code:0 Data:[] Log:Msg 0: Info: GasWanted:200000 GasUsed:3540 Tags:[{Key:[97 99 116 105 111 110] Value:[101 100 105 116 45 118 97 108 105 100 97 116 111 114] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[100 101 115 116 105 110 97 116 105 111 110 45 118 97 108 105 100 97 116 111 114] Value:[102 118 97 49 53 103 114 118 51 120 103 51 101 107 120 104 57 120 114 102 55 57 122 100 48 119 48 55 55 107 114 103 118 53 120 102 54 100 54 116 104 100] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[109 111 110 105 107 101 114] Value:[117 98 117 110 116 117 49 56] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[105 100 101 110 116 105 116 121] Value:[] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[99 111 109 112 108 101 116 101 67 111 110 115 117 109 101 100 84 120 70 101 101 45 105 114 105 115 45 97 116 116 111] Value:[34 49 55 55 48 48 48 48 48 48 48 48 48 48 48 48 34] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}] Codespace: XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}) -{ - "tags": { - "action": "edit-validator", - "completeConsumedTxFee-iris-atto": "\"177000000000000\"", - "destination-validator": "fva15grv3xg3ekxh9xrf79zd0w077krgv5xf6d6thd", - "identity": "", - "moniker": "ubuntu18" - } -} -``` diff --git a/docs/cli-client/stake/redelegate.md b/docs/cli-client/stake/redelegate.md index e211cec84..0e4813f2a 100644 --- a/docs/cli-client/stake/redelegate.md +++ b/docs/cli-client/stake/redelegate.md @@ -1,6 +1,6 @@ # iriscli stake redelegate -## Description +## Introduction Redelegate transfer delegation from one validator to another one. @@ -29,24 +29,6 @@ Users must specify the redeleagte amount. There two options can do this: `--shar ## Examples -### Redelegate illiquid tokens from one validator to another - ```shell -iriscli stake redelegate --chain-id=ChainID --from=KeyName --fee=Fee --address-validator-source=SourceValidatorAddress --address-validator-dest=DestinationValidatorAddress --shares-percent=SharesPercent -``` - -After that, you're done with redelegating specified liquid tokens from one validator to another validator. - -```txt -Committed at block 648 (tx hash: E59EE3C8F04D62DA0F5CFD89AC96402A92A56728692AEA47E8A126CDDA58E44B, response: {Code:0 Data:[11 8 185 204 185 223 5 16 247 169 147 42] Log:Msg 0: Info: GasWanted:200000 GasUsed:29085 Tags:[{Key:[97 99 116 105 111 110] Value:[98 101 103 105 110 45 114 101 100 101 108 101 103 97 116 105 111 110] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[100 101 108 101 103 97 116 111 114] Value:[102 97 97 49 48 115 48 97 114 113 57 107 104 112 108 48 99 102 122 110 103 51 113 103 120 99 120 113 48 110 121 54 104 109 99 57 115 121 116 106 102 107] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[115 111 117 114 99 101 45 118 97 108 105 100 97 116 111 114] Value:[102 118 97 49 100 97 121 117 106 100 102 110 120 106 103 103 100 53 121 100 108 118 118 103 107 101 114 112 50 115 117 112 107 110 116 104 97 106 112 99 104 50] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[100 101 115 116 105 110 97 116 105 111 110 45 118 97 108 105 100 97 116 111 114] Value:[102 118 97 49 104 50 55 120 100 119 54 116 57 108 53 106 103 118 117 110 55 54 113 100 117 52 53 107 103 114 120 57 108 113 101 100 101 56 104 112 99 100] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[101 110 100 45 116 105 109 101] Value:[11 8 185 204 185 223 5 16 247 169 147 42] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[99 111 109 112 108 101 116 101 67 111 110 115 117 109 101 100 84 120 70 101 101 45 105 114 105 115 45 97 116 116 111] Value:[34 53 56 49 55 48 48 48 48 48 48 48 48 48 48 48 48 34] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}] Codespace: XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}) -{ - "tags": { - "action": "begin-redelegation", - "completeConsumedTxFee-iris-atto": "\"5817000000000000\"", - "delegator": "faa10s0arq9khpl0cfzng3qgxcxq0ny6hmc9sytjfk", - "destination-validator": "fva1h27xdw6t9l5jgvun76qdu45kgrx9lqede8hpcd", - "end-time": "\u000b\u0008\ufffd̹\ufffd\u0005\u0010\ufffd\ufffd\ufffd*", - "source-validator": "fva1dayujdfnxjggd5ydlvvgkerp2supknthajpch2" - } -} +iriscli stake redelegate --chain-id= --from= --fee=0.004iris --address-validator-source= --address-validator-dest= --shares-percent=0.1 ``` diff --git a/docs/cli-client/stake/unbond.md b/docs/cli-client/stake/unbond.md index bc8ecdbc8..eac8b028e 100644 --- a/docs/cli-client/stake/unbond.md +++ b/docs/cli-client/stake/unbond.md @@ -1,6 +1,6 @@ # iriscli stake unbond -## Description +## Introduction Unbond shares from a validator @@ -20,7 +20,7 @@ iriscli stake unbond --help | Name, shorthand | type | Required | Default | Description | | --------------------| ----- | -------- | -------- | ------------------------------------------------------------------- | -| --address-delegator | string | true | "" | Bech address of the delegator | +| --address-validator | string | true | "" | Bech address of the validator | | --shares-amount | float | false | 0.0 | Amount of source-shares to either unbond or redelegate as a positive integer or decimal | | --shares-percent | float | false | 0.0 | Percent of source-shares to either unbond or redelegate as a positive integer or decimal >0 and <=1 | @@ -28,24 +28,6 @@ Users must specify the unbond amount. There two options can do this: `--shares-a ## Examples -### Unbond shares from a validator - ```shell -iriscli stake unbond --address-validator=ValidatorAddress --shares-percent=SharePercent --from=UnbondInitiator --chain-id=ChainID --fee=Fee -``` - -After that, you're done with unbonding shares from specified validator. - -```txt -Committed at block 851 (tx hash: A82833DE51A4127BD5D60E7F9E4CD5895F97B1B54241BCE272B68698518D9D2B, response: {Code:0 Data:[11 8 230 225 179 223 5 16 249 233 245 21] Log:Msg 0: Info: GasWanted:200000 GasUsed:16547 Tags:[{Key:[97 99 116 105 111 110] Value:[98 101 103 105 110 45 117 110 98 111 110 100 105 110 103] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[100 101 108 101 103 97 116 111 114] Value:[102 97 97 49 51 108 99 119 110 120 112 121 110 50 101 97 51 115 107 122 109 101 107 54 52 118 118 110 112 57 55 106 115 107 56 113 109 104 108 54 118 120] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[115 111 117 114 99 101 45 118 97 108 105 100 97 116 111 114] Value:[102 118 97 49 53 103 114 118 51 120 103 51 101 107 120 104 57 120 114 102 55 57 122 100 48 119 48 55 55 107 114 103 118 53 120 102 54 100 54 116 104 100] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[101 110 100 45 116 105 109 101] Value:[11 8 230 225 179 223 5 16 249 233 245 21] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[99 111 109 112 108 101 116 101 67 111 110 115 117 109 101 100 84 120 70 101 101 45 105 114 105 115 45 97 116 116 111] Value:[34 56 50 55 51 53 48 48 48 48 48 48 48 48 48 48 48 34] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}] Codespace: XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}) -{ - "tags": { - "action": "begin-unbonding", - "completeConsumedTxFee-iris-atto": "\"8273500000000000\"", - "delegator": "faa13lcwnxpyn2ea3skzmek64vvnp97jsk8qmhl6vx", - "end-time": "\u000b\u0008\ufffd\ufffd\ufffd\ufffd\u0005\u0010\ufffd\ufffd\ufffd\u0015", - "source-validator": "fva15grv3xg3ekxh9xrf79zd0w077krgv5xf6d6thd" - } - } - +iriscli stake unbond --address-validator= --shares-percent=0.1 --from= --chain-id= --fee=0.004iris ``` diff --git a/docs/cli-client/stake/unjail.md b/docs/cli-client/stake/unjail.md index 74a582207..2dd3d4368 100644 --- a/docs/cli-client/stake/unjail.md +++ b/docs/cli-client/stake/unjail.md @@ -1,6 +1,6 @@ # iriscli stake unjail -## Description +## Introduction Unjail validator previously jailed for downtime @@ -27,6 +27,3 @@ There is no unique flags. ```shell iriscli stake unjail --from= --fee=0.004iris --chain-id= ``` - -After that, you're done with unjailing specified validator. - diff --git a/docs/zh/README.md b/docs/zh/README.md index c4586a191..0d04c7b6c 100644 --- a/docs/zh/README.md +++ b/docs/zh/README.md @@ -1,55 +1,5 @@ -# 命令行客户端 +# IRISnet文档目录 +![irisnet](../pics/iris.jpg) -## 查询命令的flags - -| Name, shorthand | type | Required | Default Value | Description | -| --------------- | ---- | -------- | --------------------- | -------------------------------------------------------------------- | -| --chain-id | string | false | "" | Tendermint节点的Chain ID | -| --height | int | false | 0 | 查询某个高度的区块链数据,如果是0,这返回最新的区块链数据 | -| --help, -h | string | false | | 打印帮助信息 | -| --indent | bool | false | false | 格式化json字符串| -| --ledger | bool | false | false | 是否使用硬件钱包 | -| --node | string | false | tcp://localhost:26657 | tendermint节点的rpc地址| -| --trust-node | bool | false | true | 是否信任全节点返回的数据,如果不信任,客户端会验证查询结果的正确性 | - -每个区块链状态查询命令都包含上表中的flags,同时不同查询命令还可能会有自己独有的flags。 - -## 发送交易命令的flags - -| Name, shorthand | type | Required | Default | Description | -| -----------------| ----- | -------- | --------------------- | ------------------------------------------------------------------- | -| --account-number | int | false | 0 | 发起交易的账户的编号 | -| --async | bool | false | false | 是否异步广播交易 | -| --chain-id | string | true | "" | Tendermint节点的`Chain ID` | -| --dry-run | bool | false | false | 模拟执行交易,并返回消耗的`gas`。`--gas`指定的值会被忽略 | -| --fee | string | true | "" | 交易费 | -| --from | string | false | "" | 发送交易的账户名称 | -| --from-addr | string | false | "" | 签名地址,在`generate-only`为`true`的情况下有效 | -| --gas | int | false | 200000 | 交易的gas上限; 设置为"simulate"将自动计算相应的阈值 | -| --gas-adjustment | int | false | 1 | gas调整因子,这个值降乘以模拟执行消耗的`gas`,计算的结果返回给用户; 如果`--gas`的值不是`simulate`,这个标志将被忽略 | -| --generate-only | bool | false | false | 是否仅仅构建一个未签名的交易便返回 | -| --help, -h | string | false | | 打印帮助信息 | -| --indent | bool | false | false | 格式化json字符串 | -| --json | string | false | false | 指定返回结果的格式,`json`或者`text` | -| --ledger | bool | false | false | 是否使用硬件钱包| -| --memo | string | false | "" | 指定交易的memo字段 | -| --node | string | false | tcp://localhost:26657 | tendermint节点的rpc地址 | -| --print-response | bool | false | false | 是否打印交易返回结果,仅在`async`为true的情况下有效| -| --sequence int | int | false | 0 | 发起交易的账户的sequence | -| --trust-node | bool | false | true | 是否信任全节点返回的数据,如果不信任,客户端会验证查询结果的正确性 | - -每个发送交易的命令都包含上表中的flags,同时不同交易的命令还可能会有自己独有的flags。 - -## Command list - -1. [bank command](./bank/README.md) -2. [distribution command](./distribution/README.md) -3. [gov command](./gov/README.md) -4. [keys command](./keys/README.md) -5. [lcd command](./lcd/README.md) -6. [record command](./record/README.md) -7. [service command](./service/README.md) -8. [stake command](./stake/README.md) -9. [status command](./status/README.md) -10. [tendermint command](./tendermint/README.md) -11. [upgrade command](./upgrade/README.md) +IRIS网络是上海边界智能和Tendermint团队合作打造的跨链区块链网络,将是Cosmos网络生态中的第一个区域性枢纽(Hub),并专注于为分布式商业应用提供基础 设施和协议。 +IRISnet将面向服务的基础设施融入到Cosmos网络中,支持对包括公链、联盟链以及 现有传统商业系统的集成从而实现互联互通。通过对Cosmos网络的跨链协议进行创新 扩展,IRISnet允许数据及复杂计算跨异构网络被调用。就像忠实地在人间和天堂传递 信息的希腊彩虹女神 Iris, IRISnet的目标是成为链接数字经济和实体经济,支持构建复 杂分布式商业应用的下一代公链。 diff --git a/docs/zh/cli-client/README.md b/docs/zh/cli-client/README.md index c1901202e..c4586a191 100644 --- a/docs/zh/cli-client/README.md +++ b/docs/zh/cli-client/README.md @@ -1 +1,55 @@ -# CLi Client +# 命令行客户端 + +## 查询命令的flags + +| Name, shorthand | type | Required | Default Value | Description | +| --------------- | ---- | -------- | --------------------- | -------------------------------------------------------------------- | +| --chain-id | string | false | "" | Tendermint节点的Chain ID | +| --height | int | false | 0 | 查询某个高度的区块链数据,如果是0,这返回最新的区块链数据 | +| --help, -h | string | false | | 打印帮助信息 | +| --indent | bool | false | false | 格式化json字符串| +| --ledger | bool | false | false | 是否使用硬件钱包 | +| --node | string | false | tcp://localhost:26657 | tendermint节点的rpc地址| +| --trust-node | bool | false | true | 是否信任全节点返回的数据,如果不信任,客户端会验证查询结果的正确性 | + +每个区块链状态查询命令都包含上表中的flags,同时不同查询命令还可能会有自己独有的flags。 + +## 发送交易命令的flags + +| Name, shorthand | type | Required | Default | Description | +| -----------------| ----- | -------- | --------------------- | ------------------------------------------------------------------- | +| --account-number | int | false | 0 | 发起交易的账户的编号 | +| --async | bool | false | false | 是否异步广播交易 | +| --chain-id | string | true | "" | Tendermint节点的`Chain ID` | +| --dry-run | bool | false | false | 模拟执行交易,并返回消耗的`gas`。`--gas`指定的值会被忽略 | +| --fee | string | true | "" | 交易费 | +| --from | string | false | "" | 发送交易的账户名称 | +| --from-addr | string | false | "" | 签名地址,在`generate-only`为`true`的情况下有效 | +| --gas | int | false | 200000 | 交易的gas上限; 设置为"simulate"将自动计算相应的阈值 | +| --gas-adjustment | int | false | 1 | gas调整因子,这个值降乘以模拟执行消耗的`gas`,计算的结果返回给用户; 如果`--gas`的值不是`simulate`,这个标志将被忽略 | +| --generate-only | bool | false | false | 是否仅仅构建一个未签名的交易便返回 | +| --help, -h | string | false | | 打印帮助信息 | +| --indent | bool | false | false | 格式化json字符串 | +| --json | string | false | false | 指定返回结果的格式,`json`或者`text` | +| --ledger | bool | false | false | 是否使用硬件钱包| +| --memo | string | false | "" | 指定交易的memo字段 | +| --node | string | false | tcp://localhost:26657 | tendermint节点的rpc地址 | +| --print-response | bool | false | false | 是否打印交易返回结果,仅在`async`为true的情况下有效| +| --sequence int | int | false | 0 | 发起交易的账户的sequence | +| --trust-node | bool | false | true | 是否信任全节点返回的数据,如果不信任,客户端会验证查询结果的正确性 | + +每个发送交易的命令都包含上表中的flags,同时不同交易的命令还可能会有自己独有的flags。 + +## Command list + +1. [bank command](./bank/README.md) +2. [distribution command](./distribution/README.md) +3. [gov command](./gov/README.md) +4. [keys command](./keys/README.md) +5. [lcd command](./lcd/README.md) +6. [record command](./record/README.md) +7. [service command](./service/README.md) +8. [stake command](./stake/README.md) +9. [status command](./status/README.md) +10. [tendermint command](./tendermint/README.md) +11. [upgrade command](./upgrade/README.md) diff --git a/docs/zh/cli-client/distribution/withdraw-rewards.md b/docs/zh/cli-client/distribution/withdraw-rewards.md index 791aef94b..769c29233 100644 --- a/docs/zh/cli-client/distribution/withdraw-rewards.md +++ b/docs/zh/cli-client/distribution/withdraw-rewards.md @@ -18,10 +18,10 @@ iriscli distribution withdraw-rewards --help ## 特有的flags -| Name, shorthand | type | Required | Default | Description | +| 名称 | 类型 | 是否必填 | 默认值 | 功能描述 | | --------------------- | ----- | -------- | -------- | ------------------------------------------------------------------- | -| --only-from-validator | string | false | "" | only withdraw from this validator address (in bech) | -| --is-validator | bool | false | false | Also withdraw validator's commission | +| --only-from-validator | string | false | "" | 验证人地址,仅取回在这个验证人上的委托收益 | +| --is-validator | bool | false | false | 取回验证人佣金收益 | 不能同时使用两个flags。 diff --git a/docs/zh/cli-client/stake/README.md b/docs/zh/cli-client/stake/README.md index ea0ce126d..5cd9e0b55 100644 --- a/docs/zh/cli-client/stake/README.md +++ b/docs/zh/cli-client/stake/README.md @@ -1,41 +1,41 @@ # iriscli stake -## 描述 +## 介绍 -权益模块允许你执行权益和验证子命令 +Stake模块提供了一系列查询staking状态和发送staking交易的命令 ## 用法 -```shell -iriscli stake [command] ``` +iriscli stake [subcommand] +``` + +打印所以子命令和flags: +``` +iriscli stake --help +``` + +## 子命令 + +| 子命令 | 功能 | +| ------------------------------------------------------------- | --------------------------------------------------------------| +| [validator](validator.md) | 查询某个验证者 | +| [validators](validators.md) | 查询所有的验证者 | +| [delegation](delegation.md) | 基于委托者地址和验证者地址的委托查询 | +| [delegations](delegations.md) | 基于委托者地址的所有委托查询 | +| [unbonding-delegation](unbonding-delegation.md) | 基于委托者地址和验证者地址的unbonding-delegation记录查询 | +| [unbonding-delegations](unbonding-delegations.md) | 基于委托者地址的所有unbonding-delegation记录查询 | +| [unbonding-delegations-from](unbonding-delegations-from.md) | 基于验证者地址的所有unbonding-delegation记录查询| +| [redelegations-from](redelegations-from.md) | 基于某一验证者的所有重新委托查询 | +| [redelegation](redelegation.md) | 基于委托者地址,原源验证者地址和目标验证者地址的重新委托记录查询 | +| [redelegations](redelegations.md) | 基于委托者地址的所有重新委托记录查询 | +| [pool](pool.md) | 查询最新的权益池 | +| [parameters](parameters.md) | 查询最新的权益参数信息 | +| [signing-info](signing-info.md) | 查询验证者签名信息 | +| [create-validator](create-validator.md) | 以自委托的方式创建一个新的验证者 | +| [edit-validator](edit-validator.md) | 编辑已存在的验证者信息 | +| [delegate](delegate.md) | 委托一定代币到某个验证者 | +| [unbond](unbond.md) | 从指定的验证者解绑一定的股份 | +| [redelegate](redelegate.md) | 重新委托一定的token从一个验证者到另一个验证者 | +| [unjail](unjail.md) | 恢复之前由于宕机被惩罚的验证者的身份 | -## 相关命令 - -| 命令 | 描述 | -| --------------------------------| --------------------------------------------------------------| -| [validator](validator.md) | 查询某个验证者 | -| [validators](validators.md) | 查询所有的验证者 | -| [delegation](delegation.md) | 基于委托者地址和验证者地址的委托查询 | -| [delegations](delegations.md) | 基于委托者地址的所有委托查询 | -| [unbonding-delegation](unbonding-delegation.md) | 基于委托者地址和验证者地址的unbonding-delegation记录查询 | -| [unbonding-delegations](unbonding-delegations.md) | 基于委托者地址的所有unbonding-delegation记录查询 | -| [unbonding-delegations-from](unbonding-delegations-from.md) | 基于验证者地址的所有unbonding-delegation记录查询 | -| [redelegations-from](redelegations-from.md) | 基于某一验证者的所有重新委托查询 | -| [redelegation](redelegation.md) | 基于委托者地址,原源验证者地址和目标验证者地址的重新委托记录查询 | -| [redelegations](redelegations.md) | 基于委托者地址的所有重新委托记录查询 | -| [pool](pool.md) | 查询最新的权益池 | -| [parameters](parameters.md) | 查询最新的权益参数信息 | -| [signing-info](signing-info.md) | 查询验证者签名信息 | -| [create-validator](create-validator.md) | 以自委托的方式创建一个新的验证者 | -| [edit-validator](edit-validator.md) | 编辑已存在的验证者信息 | -| [delegate](delegate.md) | 委托一定代币到某个验证者 | -| [unbond](unbond.md) | 从指定的验证者解绑一定的股份 | -| [redelegate](redelegate.md) | 重新委托一定的token从一个验证者到另一个验证者 | -| [unjail](unjail.md) | 恢复之前由于宕机被惩罚的验证者的身份 | - -## 标志 - -| 名称, 速记 | 默认值 | 描述 | 必需 | -| --------------- | ------- | --------------- | -------- | -| --help, -h | | stake命令帮助 | | diff --git a/docs/zh/cli-client/stake/create-validator.md b/docs/zh/cli-client/stake/create-validator.md index ffbe89e51..d9d7f3212 100644 --- a/docs/zh/cli-client/stake/create-validator.md +++ b/docs/zh/cli-client/stake/create-validator.md @@ -1,8 +1,8 @@ # iriscli stake create-validator -## 描述 +## 介绍 -以自委托的方式创建一个新的验证者 +发送交易申请成为验证人,并在在此验证人上委托一定数额的token ## 用法 @@ -10,49 +10,31 @@ iriscli stake create-validator [flags] ``` -## 标志 - -| 名称, 速记 | 默认值 | 描述 | 必需 | -| ---------------------------- | --------------------- | ------------------------------------------------------------------- | -------- | -| --account-number | | [int] 用来签名交易的accountNumber | | -| --address-delegator | | [string] 委托者bech地址 | | -| --amount | | [string] 绑定的代币数量 | Yes | -| --async | | 是否异步广播交易 | | -| --chain-id | | [string] Tendermint节点的链ID | Yes | -| --commission-max-change-rate | | [string] 最大佣金变化率(每天) | Yes | -| --commission-max-rate | | [string] 最大佣金率 | Yes | -| --commission-rate | | [string] 初始佣金率 | Yes | -| --details | | [string] 可选details | | -| --dry-run | | 忽略--gas标志并进行本地的交易仿真 | | -| --fee | | [string] 交易费用 | Yes | -| --from | | [string] 用来签名的私钥名 | Yes | -| --from-addr | | [string] 指定generate-only模式下的from address | | -| --gas | 200000 | [string] 单次交易的gas上限; 设置为"simulate"将自动计算相应的阈值 | | -| --gas-adjustment | 1 | [float] 这个调整因子将乘以交易仿真返回的估计值; 如果手动设置了gas的上限,这个标志将被忽略 | | -| --generate-only | | 构建一个未签名交易并将其打印到标准输出 | | -| --genesis-format | | 以gen-tx的格式导出交易; 其暗含 --generate-only | | -| --help, -h | | create-validator命令帮助 | | -| --identity | | [string] 可选身份签名 (ex. UPort or Keybase) | | -| --indent | | 在JSON响应中添加缩进 | | -| --ip | | [string] N节点的公有IP,仅开启--genesis-format时生效 | | -| --json | | 以json形式输出 | | -| --ledger | | 使用连接的硬件记账设备 | | -| --memo | | [string] 发送交易时的备忘录 | | -| --moniker | | [string] 验证者名字 | | -| --node | tcp://localhost:26657 | [string] Tendermint远程过程调用的接口\<主机>:\<端口> | | -| --node-id | | [string] 节点ID | | -| --print-response | | 返回交易响应 (当且仅当同步模式下使用) | | -| --pubkey | | [string] 验证者的Go-Amino编码的16进制公钥. 对于Ed25519,go-amino的16进制前缀为1624de6220 | Yes | -| --sequence | | [int] 用来签名交易的sequence | | -| --trust-node | true | 关闭响应结果校验 | | -| --website | | [string] 选填的网站 | | - -## 例子 - -### 创建新的验证者 - -```shell -iriscli stake create-validator --chain-id=ChainID --from=KeyName --fee=Fee --pubkey=ValidatorPublicKey --commission-max-change-rate=CommissionMaxChangeRate --commission-max-rate=CommissionMaxRate --commission-rate=CommissionRate --amount=Coins +打印帮助信息 ``` +iriscli stake create-validator --help +``` + +## 特有的flags + +| 名称 | 类型 | 是否必填 | 默认值 | 功能描述 | +| ---------------------------- | ----- | -------- | -------- | ------------------------------------ | +| --amount | string | true | "" | 委托token的数量 | +| --commission-max-change-rate | float | true | 0.0 | 佣金比率每天变化的最大数量 | +| --commission-max-rate | float | true | 0.0 | 最大佣金比例 | +| --commission-rate | float | true | 0.0 | 初始佣金比例 | +| --details | string | false | "" | 验证人节点的详细信息 | +| --genesis-format | bool | false | false | 是否已genesis transaction的方式倒出 | +| --identity | string | false | "" | 身份信息的签名 | +| --ip | string | false | "" | 验证人节点的IP | +| --moniker | string | true | "" | 验证人节点名称 | +| --pubkey | string | true | "" | Amino编码的验证人公钥 | +| --website | string | false | "" | 验证人节点的网址 | + +## 示例 + +``` +iriscli stake create-validator --chain-id= --from= --fee=0.004iris --pubkey= --commission-max-change-rate=0.01 --commission-max-rate=0.2 --commission-rate=0.1 --amount=100iris --moniker= +``` + -运行上述命令之后,你便成功地创建了一个验证者。 diff --git a/docs/zh/cli-client/stake/delegate.md b/docs/zh/cli-client/stake/delegate.md index bf50ec29d..fe0935904 100644 --- a/docs/zh/cli-client/stake/delegate.md +++ b/docs/zh/cli-client/stake/delegate.md @@ -1,8 +1,8 @@ # iriscli stake delegate -## 描述 +## 介绍 -委托一定代币到某个验证者 +发送委托交易 ## 用法 @@ -10,50 +10,20 @@ iriscli stake delegate [flags] ``` -## 标志 - -| 名称, 速记 | 默认值 | 描述 | 必需 | -| ---------------------------- | --------------------- | ------------------------------------------------------------------- | -------- | -| --account-number | | [int] 用来签名交易的accountNumber | | -| --address-validator | | [string] 验证者bech地址 | Yes | -| --amount | | [string] 绑定的代币数量 | Yes | -| --async | | 是否异步广播交易 | | -| --chain-id | | [string] Tendermint节点的链ID | Yes | -| --dry-run | | 忽略--gas标志并进行本地的交易仿真 | | -| --fee | | [string] 交易费用 | Yes | -| --from | | [string] 用来签名的私钥名 | Yes | -| --from-addr | | [string] 指定generate-only模式下的from address | | -| --gas | 200000 | [string] 单次交易的gas上限; 设置为"simulate"将自动计算相应的阈值 | | -| --gas-adjustment | 1 | [float] 这个调整因子将乘以交易仿真返回的估计值; 如果手动设置了gas的上限,这个标志将被忽略 | | -| --generate-only | | 构建一个未签名交易并将其打印到标准输出 | | -| --help, -h | | delegate命令帮助 | | -| --indent | | 在JSON响应中添加缩进 | | -| --json | | 以json形式输出 | | -| --ledger | | 使用连接的硬件记账设备 | | -| --memo | | [string] 发送交易时的备忘录 | | -| --node | tcp://localhost:26657 | [string] Tendermint远程过程调用的接口\<主机>:\<端口> | | -| --print-response | | 返回交易响应 (当且仅当同步模式下使用) | | -| --sequence int | | [int] 用来签名交易的sequence | | -| --trust-node | true | 关闭响应结果校验 | | - -## 例子 - -### 委托一定代币到某个验证者 - -```shell -iriscli stake delegate --chain-id=ChainID --from=KeyName --fee=Fee --amount=CoinstoBond --address-validator=ValidatorOwnerAddress +打印帮助信息 +``` +iriscli stake delegate --help ``` -运行成功以后,返回的结果如下: - -```txt -Committed at block 2352 (tx hash: 2069F0453619637EE67EFB0CFC53713AF28A0BB89137DEB4574D8B13E723999B, response: {Code:0 Data:[] Log:Msg 0: Info: GasWanted:200000 GasUsed:15993 Tags:[{Key:[97 99 116 105 111 110] Value:[100 101 108 101 103 97 116 101] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[100 101 108 101 103 97 116 111 114] Value:[102 97 97 49 51 108 99 119 110 120 112 121 110 50 101 97 51 115 107 122 109 101 107 54 52 118 118 110 112 57 55 106 115 107 56 113 109 104 108 54 118 120] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[100 101 115 116 105 110 97 116 105 111 110 45 118 97 108 105 100 97 116 111 114] Value:[102 118 97 49 53 103 114 118 51 120 103 51 101 107 120 104 57 120 114 102 55 57 122 100 48 119 48 55 55 107 114 103 118 53 120 102 54 100 54 116 104 100] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[99 111 109 112 108 101 116 101 67 111 110 115 117 109 101 100 84 120 70 101 101 45 105 114 105 115 45 97 116 116 111] Value:[34 55 57 57 54 53 48 48 48 48 48 48 48 48 48 48 48 34] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}] Codespace: XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}) -{ - "tags": { - "action": "delegate", - "completeConsumedTxFee-iris-atto": "\"7996500000000000\"", - "delegator": "faa13lcwnxpyn2ea3skzmek64vvnp97jsk8qmhl6vx", - "destination-validator": "fva15grv3xg3ekxh9xrf79zd0w077krgv5xf6d6thd" - } - } +## 特有的flags + +| 名称 | 类型 | 是否必填 | 默认值 | 功能描述 | +| --------------------| ----- | -------- | -------- | ---------------- | +| --address-delegator | string | true | "" | 验证人地址 | +| --amount | string | true | "" | 委托的token数量 | + +## 示例 + +``` +iriscli stake delegate --chain-id=ChainID --from=KeyName --fee=Fee --amount=CoinstoBond --address-validator=ValidatorOwnerAddress ``` diff --git a/docs/zh/cli-client/stake/edit-validator.md b/docs/zh/cli-client/stake/edit-validator.md index 2c97c6fc6..76c171623 100644 --- a/docs/zh/cli-client/stake/edit-validator.md +++ b/docs/zh/cli-client/stake/edit-validator.md @@ -1,71 +1,32 @@ # iriscli stake edit-validator -## 描述 +## 介绍 -编辑已存在的验证者信息 +修改验证的的参数,包括佣金比率,验证人节点名称以及其他描述信息 ## 用法 ``` iriscli stake edit-validator [flags] ``` +打印帮助信息 +```shell +iriscli stake edit-validator --help +``` -## 标志 +## 特有flags -| 名称, 速记 | 默认值 | 描述 | 必需 | -| ---------------------------- | --------------------- | ------------------------------------------------------------------- | -------- | -| --account-number | | [int] 用来签名交易的accountNumber | | -| --address-delegator | | [string] 委托者bech地址 | | -| --amount | | [string] 绑定的代币数量 | | -| --async | | 是否异步广播交易 | | -| --chain-id | | [string] Tendermint节点的链ID | Yes | -| --commission-max-change-rate | | [string] 最大佣金变化率(每天) | | -| --commission-max-rate | | [string] 最大佣金率 | | -| --commission-rate | | [string] [string] 初始佣金率 | | -| --details | | [string] 可选details | | -| --dry-run | | 忽略--gas标志并进行本地的交易仿真 | | -| --fee | | [string] 交易费用 | Yes | -| --from | | [string] 用来签名的私钥名 | Yes | -| --from-addr | | [string] 指定generate-only模式下的from address | | -| --gas | 200000 | [string] 单次交易的gas上限; 设置为"simulate"将自动计算相应的阈值 | | -| --gas-adjustment | 1 | [float] 这个调整因子将乘以交易仿真返回的估计值; 如果手动设置了gas的上限,这个标志将被忽略 | | -| --generate-only | | 构建一个未签名交易并将其打印到标准输出 | | -| --genesis-format | | 以gen-tx的格式导出交易; 其暗含 --generate-only | | -| --help, -h | | edit-validator命令帮助 | | -| --identity | | [string] 可选身份签名 (ex. UPort or Keybase) | | -| --indent | | 在JSON响应中添加缩进 | | -| --ip | | [string] N节点的公有IP,仅开启--genesis-format时生效 | | -| --json | | 以json形式输出 | | -| --ledger | | 使用连接的硬件记账设备 | | -| --memo | | [string] 发送交易时的备忘录 | | -| --moniker | | [string] 验证者名字 | | -| --node | tcp://localhost:26657 | [string] Tendermint远程过程调用的接口\<主机>:\<端口> | | -| --node-id | | [string] 节点ID | | -| --print-response | | 返回交易响应 (当且仅当同步模式下使用) | | -| --pubkey | | [string] 验证者的Go-Amino编码的16进制公钥. 对于Ed25519,go-amino的16进制前缀为1624de6220 | | -| --sequence | | [int] 用来签名交易的sequence | | -| --trust-node | true | 关闭响应结果校验 | | -| --website | | [string] 选填网站 | | +| 名称 | 类型 | 是否必填 | 默认值 | 功能描述 | +| --------------------| ----- | -------- | -------- | ------------------------------------------------------------------- | +| --commission-rate | string | float | 0.0 | 佣金比率 | +| --moniker | string | false | "" | 验证人名称 | +| --identity | string | false | "" | 身份签名 | +| --website | string | false | "" | 网址 | +| --details | string | false | "" | 验证人节点详细信息 | -## 例子 -### 编辑已存在的验证者信息 +## 示例 ```shell -iriscli stake edit-validator --from=KeyName --chain-id=ChainID --fee=Fee --memo=YourMemo -``` - -运行成功以后,返回的结果如下: - -```txt -Committed at block 2160 (tx hash: C48CABDA1183B5319003433EB1FDEBE5A626E00BD319F1A84D84B6247E9224D1, response: {Code:0 Data:[] Log:Msg 0: Info: GasWanted:200000 GasUsed:3540 Tags:[{Key:[97 99 116 105 111 110] Value:[101 100 105 116 45 118 97 108 105 100 97 116 111 114] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[100 101 115 116 105 110 97 116 105 111 110 45 118 97 108 105 100 97 116 111 114] Value:[102 118 97 49 53 103 114 118 51 120 103 51 101 107 120 104 57 120 114 102 55 57 122 100 48 119 48 55 55 107 114 103 118 53 120 102 54 100 54 116 104 100] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[109 111 110 105 107 101 114] Value:[117 98 117 110 116 117 49 56] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[105 100 101 110 116 105 116 121] Value:[] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[99 111 109 112 108 101 116 101 67 111 110 115 117 109 101 100 84 120 70 101 101 45 105 114 105 115 45 97 116 116 111] Value:[34 49 55 55 48 48 48 48 48 48 48 48 48 48 48 48 34] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}] Codespace: XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}) -{ - "tags": { - "action": "edit-validator", - "completeConsumedTxFee-iris-atto": "\"177000000000000\"", - "destination-validator": "fva15grv3xg3ekxh9xrf79zd0w077krgv5xf6d6thd", - "identity": "", - "moniker": "ubuntu18" - } -} +iriscli stake edit-validator --from= --chain-id= --fee=0.004iris --commission-rate=0.15 ``` diff --git a/docs/zh/cli-client/stake/redelegate.md b/docs/zh/cli-client/stake/redelegate.md index db9329b86..b1e236181 100644 --- a/docs/zh/cli-client/stake/redelegate.md +++ b/docs/zh/cli-client/stake/redelegate.md @@ -1,8 +1,8 @@ # iriscli stake redelegate -## 描述 +## 介绍 -重新委托一定的token从一个验证者到另一个验证者 +把某个委托的一部分或者全部从一个验证人转移到另外一个验证人 ## 用法 @@ -10,54 +10,25 @@ iriscli stake redelegate [flags] ``` -## 标志 - -| 名称, 速记 | 默认值 | 描述 | 必需 | -| ---------------------------- | --------------------- | ------------------------------------------------------------------- | -------- | -| --account-number | | [int] 用来签名交易的accountNumber | | -| --address-validator-dest | | [string] 目标验证者bech地址 | Yes | -| --address-validator-source | | [string] 源验证者bech地址 | Yes | -| --async | | 是否异步广播交易 | | -| --chain-id | | [string] Tendermint节点的链ID | Yes | -| --dry-run | | 忽略--gas标志并进行本地的交易仿真 | | -| --fee | | [string] 交易费用 | Yes | -| --from | | [string] 用来签名的私钥名 | Yes | -| --from-addr | | [string] 指定generate-only模式下的from address | | -| --gas | 200000 | [string] 单次交易的gas上限; 设置为"simulate"将自动计算相应的阈值 | | -| --gas-adjustment | 1 | [float] 这个调整因子将乘以交易仿真返回的估计值; 如果手动设置了gas的上限,这个标志将被忽略 || -| --generate-only | | 构建一个未签名交易并将其打印到标准输出 | | -| --help, -h | | redelegate命令帮助 | | -| --indent | | 在JSON响应中添加缩进 | | -| --json | | 以json形式输出 | | -| --ledger | | 使用连接的硬件记账设备 | | -| --memo | | [string] 发送交易时的备忘录 | | -| --node | tcp://localhost:26657 | [string] Tendermint远程过程调用的接口\<主机>:\<端口> | | -| --print-response | | 返回交易响应 (当且仅当同步模式下使用) | | -| --sequence | | [int] 用来签名交易的sequence | | -| --shares-amount | | [string] 指定重新委托给其他验证者的股份 | | -| --shares-percent | | [string] 指定重新委托给其他验证者的股份比例,位于0到1之间的正数 | | -| --trust-node | true | 关闭响应结果校验 | | - -## 例子 - -### 重新委托一定的token从一个验证者到另一个验证者 - -```shell -iriscli stake redelegate --chain-id=ChainID --from=KeyName --fee=Fee --address-validator-source=SourceValidatorAddress --address-validator-dest=DestinationValidatorAddress --shares-percent=SharesPercent +打印帮助信息 ``` +iriscli stake redelegate --help +``` + +## 特有flags + +| 名称 | 类型 | 是否必填 | 默认值 | 功能描述 | +| -------------------------- | ----- | -------- | -------- | ------------------------------------------------------------------- | +| --address-validator-dest | string | true | "" | 目标验证人地址 | +| --address-validator-source | string | true | "" | 源验证人地址 | +| --shares-amount | float | false | 0.0 | 转移的share数量,正数 | +| --shares-percent | float | false | 0.0 | 转移的比率,0到1之间的正数 | + +用户可以用`--shares-amount`或者`--shares-percent`指定装委托的token数量。记住,这两个参数不可同时使用。 -运行成功以后,返回的结果如下: - -```txt -Committed at block 648 (tx hash: E59EE3C8F04D62DA0F5CFD89AC96402A92A56728692AEA47E8A126CDDA58E44B, response: {Code:0 Data:[11 8 185 204 185 223 5 16 247 169 147 42] Log:Msg 0: Info: GasWanted:200000 GasUsed:29085 Tags:[{Key:[97 99 116 105 111 110] Value:[98 101 103 105 110 45 114 101 100 101 108 101 103 97 116 105 111 110] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[100 101 108 101 103 97 116 111 114] Value:[102 97 97 49 48 115 48 97 114 113 57 107 104 112 108 48 99 102 122 110 103 51 113 103 120 99 120 113 48 110 121 54 104 109 99 57 115 121 116 106 102 107] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[115 111 117 114 99 101 45 118 97 108 105 100 97 116 111 114] Value:[102 118 97 49 100 97 121 117 106 100 102 110 120 106 103 103 100 53 121 100 108 118 118 103 107 101 114 112 50 115 117 112 107 110 116 104 97 106 112 99 104 50] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[100 101 115 116 105 110 97 116 105 111 110 45 118 97 108 105 100 97 116 111 114] Value:[102 118 97 49 104 50 55 120 100 119 54 116 57 108 53 106 103 118 117 110 55 54 113 100 117 52 53 107 103 114 120 57 108 113 101 100 101 56 104 112 99 100] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[101 110 100 45 116 105 109 101] Value:[11 8 185 204 185 223 5 16 247 169 147 42] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[99 111 109 112 108 101 116 101 67 111 110 115 117 109 101 100 84 120 70 101 101 45 105 114 105 115 45 97 116 116 111] Value:[34 53 56 49 55 48 48 48 48 48 48 48 48 48 48 48 48 34] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}] Codespace: XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}) -{ - "tags": { - "action": "begin-redelegation", - "completeConsumedTxFee-iris-atto": "\"5817000000000000\"", - "delegator": "faa10s0arq9khpl0cfzng3qgxcxq0ny6hmc9sytjfk", - "destination-validator": "fva1h27xdw6t9l5jgvun76qdu45kgrx9lqede8hpcd", - "end-time": "\u000b\u0008\ufffd̹\ufffd\u0005\u0010\ufffd\ufffd\ufffd*", - "source-validator": "fva1dayujdfnxjggd5ydlvvgkerp2supknthajpch2" - } -} +## 示例 + +``` +iriscli stake redelegate --chain-id= --from= --fee=0.004iris --address-validator-source= --address-validator-dest= --shares-percent=0.1 ``` + diff --git a/docs/zh/cli-client/stake/unbond.md b/docs/zh/cli-client/stake/unbond.md index 0bd1dcc2d..043693757 100644 --- a/docs/zh/cli-client/stake/unbond.md +++ b/docs/zh/cli-client/stake/unbond.md @@ -1,8 +1,8 @@ # iriscli stake unbond -## 描述 +## 介绍 -从指定的验证者解绑一定的股份 +Unbond shares from a validator ## 用法 @@ -10,53 +10,24 @@ iriscli stake unbond [flags] ``` -## 标志 - -| 名称, 速记 | 默认值 | 描述 | 必需 | -| --------------------- | --------------------- | ------------------------------------------------------------------------------------------------------------- | -------- | -| --account-number | | [int] 用来签名交易的accountNumber | | -| --address-validator | | [string] 验证者bech地址 | Yes | -| --async | | 是否异步广播交易 | | -| --chain-id | | [string] Tendermint节点的链ID | Yes | -| --dry-run | | 忽略--gas标志并进行本地的交易仿真 | | -| --fee | | [string] 交易费用 | Yes | -| --from | | [string] 用来签名的私钥名 | Yes | -| --from-addr | | [string] [string] 指定generate-only模式下的from address | | -| --gas | 200000 | [string] 单次交易的gas上限; 设置为"simulate"将自动计算相应的阈值 | | -| --gas-adjustment | 1 | [float] 这个调整因子将乘以交易仿真返回的估计值; 如果手动设置了gas的上限,这个标志将被忽略 | | -| --generate-only | | 构建一个未签名交易并将其打印到标准输出 | | -| --help, -h | | unbond命令帮助 | | -| --indent | | 在JSON响应中添加缩进 | | -| --json | | 以json形式输出 | | -| --ledger | | 使用连接的硬件记账设 | | -| --memo | | [string] 发送交易时的备忘录 | | -| --node | tcp://localhost:26657 | [string] Tendermint远程过程调用的接口\<主机>:\<端口> | | -| --print-response | | 返回交易响应 (当且仅当同步模式下使用) | | -| --sequence | | [int] 用来签名交易的sequence | | -| --shares-amount | | [string] 指定解绑的股份数 | | -| --shares-percent | | [string] 指定解绑的股份比例,为0到1之间的正数 | | -| --trust-node | true | 关闭响应结果校验 | | - -## 例子 - -### 从指定的验证者解绑一定的股份 - -```shell -iriscli stake unbond --address-validator=ValidatorAddress --shares-percent=SharePercent --from=UnbondInitiator --chain-id=ChainID --fee=Fee +打印帮助信息 + +``` +iriscli stake unbond --help ``` -运行成功以后,返回的结果如下: +## 特有flags + +| 名称 | 类型 | 是否必填 | 默认值 | 功能描述 | +| --------------------| ----- | -------- | -------- | ------------------------------------------------------------------- | +| --address-validator | string | true | "" | 验证人地址 | +| --shares-amount | float | false | 0.0 | 解绑的share数量,正数 | +| --shares-percent | float | false | 0.0 | 解绑的比率,0到1之间的正数 | -```txt -Committed at block 851 (tx hash: A82833DE51A4127BD5D60E7F9E4CD5895F97B1B54241BCE272B68698518D9D2B, response: {Code:0 Data:[11 8 230 225 179 223 5 16 249 233 245 21] Log:Msg 0: Info: GasWanted:200000 GasUsed:16547 Tags:[{Key:[97 99 116 105 111 110] Value:[98 101 103 105 110 45 117 110 98 111 110 100 105 110 103] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[100 101 108 101 103 97 116 111 114] Value:[102 97 97 49 51 108 99 119 110 120 112 121 110 50 101 97 51 115 107 122 109 101 107 54 52 118 118 110 112 57 55 106 115 107 56 113 109 104 108 54 118 120] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[115 111 117 114 99 101 45 118 97 108 105 100 97 116 111 114] Value:[102 118 97 49 53 103 114 118 51 120 103 51 101 107 120 104 57 120 114 102 55 57 122 100 48 119 48 55 55 107 114 103 118 53 120 102 54 100 54 116 104 100] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[101 110 100 45 116 105 109 101] Value:[11 8 230 225 179 223 5 16 249 233 245 21] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0} {Key:[99 111 109 112 108 101 116 101 67 111 110 115 117 109 101 100 84 120 70 101 101 45 105 114 105 115 45 97 116 116 111] Value:[34 56 50 55 51 53 48 48 48 48 48 48 48 48 48 48 48 34] XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}] Codespace: XXX_NoUnkeyedLiteral:{} XXX_unrecognized:[] XXX_sizecache:0}) -{ - "tags": { - "action": "begin-unbonding", - "completeConsumedTxFee-iris-atto": "\"8273500000000000\"", - "delegator": "faa13lcwnxpyn2ea3skzmek64vvnp97jsk8qmhl6vx", - "end-time": "\u000b\u0008\ufffd\ufffd\ufffd\ufffd\u0005\u0010\ufffd\ufffd\ufffd\u0015", - "source-validator": "fva15grv3xg3ekxh9xrf79zd0w077krgv5xf6d6thd" - } - } +用户可以用`--shares-amount`或者`--shares-percent`指定解绑定的token数量,这两个参数不可同时使用。 +## 示例 + +``` +iriscli stake unbond --address-validator= --shares-percent=0.1 --from= --chain-id= --fee=0.004iris ``` diff --git a/docs/zh/cli-client/stake/unjail.md b/docs/zh/cli-client/stake/unjail.md index 24eec0434..c9cd36a8d 100644 --- a/docs/zh/cli-client/stake/unjail.md +++ b/docs/zh/cli-client/stake/unjail.md @@ -1,49 +1,27 @@ # iriscli stake unjail -## 描述 +## 介绍 -恢复之前由于宕机被惩罚的验证者的身份 +Unjail validator previously jailed for downtime ## 用法 ``` -iriscli stake redelegate [flags] +iriscli stake unjail [flags] ``` -## 标志 - -| 名称, 速记 | 默认值 | 描述 | 必需 | -| ---------------------------- | --------------------- | ------------------------------------------------------------------- | -------- | -| --account-number | | [int] 用来签名交易的accountNumber | | -| --address-validator-dest | | [string] 目标验证者bech地址 | | -| --address-validator-source | | [string] 源验证者bech地址 | | -| --async | | 是否异步广播交易 | | -| --chain-id | | [string] Tendermint节点的链ID | Yes | -| --dry-run | | 忽略--gas标志并进行本地的交易仿真 | | -| --fee | | [string] 交易费用 | Yes | -| --from | | [string] 用来签名的私钥名 | Yes | -| --from-addr | | [string] 指定generate-only模式下的from address | | -| --gas | 200000 | [string] 单次交易的gas上限; 设置为"simulate"将自动计算相应的阈值 | | -| --gas-adjustment | 1 | [float] 这个调整因子将乘以交易仿真返回的估计值; 如果手动设置了gas的上限,这个标志将被忽略 || -| --generate-only | | 构建一个未签名交易并将其打印到标准输出 | | -| --help, -h | | unjail命令帮助 | | -| --indent | | 在JSON响应中添加缩进 | | -| --json | | 以json形式输出 | | -| --ledger | | 使用连接的硬件记账设备 | | -| --memo | | [string] 发送交易时的备忘录 | | -| --node | tcp://localhost:26657 | [string] Tendermint远程过程调用的接口\<主机>:\<端口> | | -| --print-response | | 返回交易响应 (当且仅当同步模式下使用) | | -| --sequence int | | [int] 用来签名交易的sequence | | -| --shares-amount | | [string] 指定恢复验证者身份是的股份 | | -| --shares-percent | | [string] 指定恢复验证者身份是的股份比,为0到1之间的正数 | | -| --trust-node | true | 关闭响应结果校验 | | - -## 例子 - -### 恢复之前由于宕机被惩罚的验证者的身份 +打印帮助信息 ```shell -iriscli stake unjail --from=KeyName --fee=Fee --chain-id=ChainID +iriscli stake unjail --help ``` -执行完成以后,你成功地恢复了指定的验证者的身份。 +## 特有flags + +没有特有的flags + +## 示例 + +```shell +iriscli stake unjail --from= --fee=0.004iris --chain-id= +``` From 6b5391107ece9838bc0a792a96b89f7a7860090f Mon Sep 17 00:00:00 2001 From: HaoyangLiu Date: Sat, 17 Nov 2018 15:28:06 +0800 Subject: [PATCH 4/5] Improve docs for distribution cli-client --- docs/cli-client/distribution/README.md | 10 +++++----- docs/cli-client/distribution/delegation-distr-info.md | 5 ++--- docs/cli-client/distribution/delegator-distr-info.md | 3 +-- docs/cli-client/distribution/set-withdraw-address.md | 3 +-- docs/cli-client/distribution/validator-distr-info.md | 3 +-- docs/cli-client/distribution/withdraw-address.md | 2 +- docs/cli-client/distribution/withdraw-rewards.md | 2 +- docs/cli-client/stake/README.md | 2 +- 8 files changed, 13 insertions(+), 17 deletions(-) diff --git a/docs/cli-client/distribution/README.md b/docs/cli-client/distribution/README.md index e7dca38c8..3d5b25648 100644 --- a/docs/cli-client/distribution/README.md +++ b/docs/cli-client/distribution/README.md @@ -1,22 +1,22 @@ # iriscli distribution -## Description +## introduction -This document description how to use the the command line interface of distribution module. +This document describe how to use the the command line interfaces of distribution module. ## Usage ```shell -iriscli distribution [subcommand] +iriscli distribution [subcommand] [flags] ``` -Print all supported subcommands and options: +Print all supported subcommands and flags: ```shell iriscli distribution --help ``` -## Available Commands +## Available Subommands | Name | Description | | --------------------------------| --------------------------------------------------------------| diff --git a/docs/cli-client/distribution/delegation-distr-info.md b/docs/cli-client/distribution/delegation-distr-info.md index a070ac4fa..9f543be7b 100644 --- a/docs/cli-client/distribution/delegation-distr-info.md +++ b/docs/cli-client/distribution/delegation-distr-info.md @@ -1,6 +1,6 @@ # iriscli distribution delegation-distr-info -## Description +## introduction Query delegation distribution information @@ -10,8 +10,7 @@ Query delegation distribution information iriscli distribution delegation-distr-info [flags] ``` -Print all supported options: - +Print help messages: ```shell iriscli distribution delegation-distr-info --help ``` diff --git a/docs/cli-client/distribution/delegator-distr-info.md b/docs/cli-client/distribution/delegator-distr-info.md index 1fa122735..f2c0077ce 100644 --- a/docs/cli-client/distribution/delegator-distr-info.md +++ b/docs/cli-client/distribution/delegator-distr-info.md @@ -10,8 +10,7 @@ Query delegator distribution information iriscli distribution delegator-distr-info [flags] ``` -Print all supported options: - +Print help messages: ```shell iriscli distribution delegator-distr-info --help ``` diff --git a/docs/cli-client/distribution/set-withdraw-address.md b/docs/cli-client/distribution/set-withdraw-address.md index bc9b5ed4c..95926ead8 100644 --- a/docs/cli-client/distribution/set-withdraw-address.md +++ b/docs/cli-client/distribution/set-withdraw-address.md @@ -10,8 +10,7 @@ Set withdraw address of a delegator iriscli distribution set-withdraw-addr [withdraw-addr] [flags] ``` -Print all supported options: - +Print help messages: ```shell iriscli distribution set-withdraw-addr --help ``` diff --git a/docs/cli-client/distribution/validator-distr-info.md b/docs/cli-client/distribution/validator-distr-info.md index 486c4142a..d006e61ce 100644 --- a/docs/cli-client/distribution/validator-distr-info.md +++ b/docs/cli-client/distribution/validator-distr-info.md @@ -10,8 +10,7 @@ Query validator distribution information iriscli distribution validator-distr-info [flags] ``` -Print all supported options: - +Print help messages: ```shell iriscli distribution validator-distr-info --help ``` diff --git a/docs/cli-client/distribution/withdraw-address.md b/docs/cli-client/distribution/withdraw-address.md index be1c4fcb6..c47549c26 100644 --- a/docs/cli-client/distribution/withdraw-address.md +++ b/docs/cli-client/distribution/withdraw-address.md @@ -10,7 +10,7 @@ Query withdraw address of a delegator iriscli distribution withdraw-address [delegator address] [flags] ``` -Print all supported options: +Print help messages: ```shell iriscli distribution withdraw-address --help diff --git a/docs/cli-client/distribution/withdraw-rewards.md b/docs/cli-client/distribution/withdraw-rewards.md index c6e44f78f..98a18d59d 100644 --- a/docs/cli-client/distribution/withdraw-rewards.md +++ b/docs/cli-client/distribution/withdraw-rewards.md @@ -10,7 +10,7 @@ Withdraw rewards iriscli distribution withdraw-rewards [flags] ``` -Print all supported options: +Print help messages: ```shell iriscli distribution withdraw-rewards --help diff --git a/docs/cli-client/stake/README.md b/docs/cli-client/stake/README.md index 291e8a1e8..1d0ada080 100644 --- a/docs/cli-client/stake/README.md +++ b/docs/cli-client/stake/README.md @@ -7,7 +7,7 @@ Stake module provides a set of subcommands to query staking state and send staki ## Usage ```shell -iriscli stake [subcommand] +iriscli stake [subcommand] [flags] ``` Print all supported subcommands and flags: From 8cddde9e55ef75a44d715dc20a889dbc9da405d1 Mon Sep 17 00:00:00 2001 From: HaoyangLiu Date: Sat, 17 Nov 2018 15:49:37 +0800 Subject: [PATCH 5/5] Correct some spell error and grammar error --- docs/cli-client/README.md | 20 ++++++++++--------- docs/cli-client/distribution/README.md | 2 +- .../distribution/delegation-distr-info.md | 6 +++--- .../distribution/delegator-distr-info.md | 10 +++++----- .../distribution/set-withdraw-address.md | 10 +++++----- .../distribution/validator-distr-info.md | 8 ++++---- .../distribution/withdraw-address.md | 8 ++++---- .../distribution/withdraw-rewards.md | 12 +++++------ docs/cli-client/stake/redelegate.md | 4 ++-- docs/cli-client/stake/unbond.md | 4 ++-- docs/cli-client/stake/unjail.md | 2 +- docs/zh/cli-client/README.md | 2 +- 12 files changed, 45 insertions(+), 43 deletions(-) diff --git a/docs/cli-client/README.md b/docs/cli-client/README.md index f72b62dcc..b2d562167 100644 --- a/docs/cli-client/README.md +++ b/docs/cli-client/README.md @@ -1,22 +1,22 @@ -# CLi Client +# Command Line Client -## Global flags for query commands +## Global flags of query commands -All query commands has their unique flags and these global flags. +All query commands has these global flags. Their unique flags will be introduced later. | Name, shorthand | type | Required | Default Value | Description | | --------------- | ---- | -------- | --------------------- | -------------------------------------------------------------------- | | --chain-id | string | false | "" | Chain ID of tendermint node | -| --height | int | false | 0 | block height to query, omit to get most recent provable block | -| --help, -h | string | false | | help for delegation | +| --height | int | false | 0 | Block height to query, omit to get most recent provable block | +| --help, -h | string | false | | Print help message | | --indent | bool | false | false | Add indent to JSON response | | --ledger | bool | false | false | Use a connected Ledger device | | --node | string | false | tcp://localhost:26657 | \:\ to tendermint rpc interface for this chain | | --trust-node | bool | false | true | Don't verify proofs for responses | -## Global flags for commands to send transactions +## Global flags of commands to send transactions -All commands which can be used to send transactions has their unique flags and these global flags. +All commands which can be used to send transactions have these global flags. Their unique flags will be introduced later. | Name, shorthand | type | Required | Default | Description | | -----------------| ----- | -------- | --------------------- | ------------------------------------------------------------------- | @@ -30,7 +30,7 @@ All commands which can be used to send transactions has their unique flags and t | --gas | int | false | 200000 | Gas limit to set per-transaction; set to "simulate" to calculate required gas automatically | | --gas-adjustment | int | false | 1 | Adjustment factor to be multiplied against the estimate returned by the tx simulation; if the gas limit is set | | --generate-only | bool | false | false | Build an unsigned transaction and write it to STDOUT | -| --help, -h | string | false | | Help for delegate | +| --help, -h | string | false | | Print help message | | --indent | bool | false | false | Add indent to JSON response | | --json | string | false | false | Return output in json format | | --ledger | bool | false | false | Use a connected Ledger device | @@ -40,7 +40,9 @@ All commands which can be used to send transactions has their unique flags and t | --sequence int | int | false | 0 | Sequence number to sign the tx | | --trust-node | bool | false | true | Don't verify proofs for responses | -## Command list +## Modules list + +Each modules provides a set of command line interfaces. Here we sort these commands by modules. 1. [bank command](./bank/README.md) 2. [distribution command](./distribution/README.md) diff --git a/docs/cli-client/distribution/README.md b/docs/cli-client/distribution/README.md index 3d5b25648..9aec53571 100644 --- a/docs/cli-client/distribution/README.md +++ b/docs/cli-client/distribution/README.md @@ -2,7 +2,7 @@ ## introduction -This document describe how to use the the command line interfaces of distribution module. +This document describes how to use the the command line interfaces of distribution module. ## Usage diff --git a/docs/cli-client/distribution/delegation-distr-info.md b/docs/cli-client/distribution/delegation-distr-info.md index 9f543be7b..c5734a0d8 100644 --- a/docs/cli-client/distribution/delegation-distr-info.md +++ b/docs/cli-client/distribution/delegation-distr-info.md @@ -2,7 +2,7 @@ ## introduction -Query delegation distribution information +Query a delegation distribution information ## Usage @@ -11,7 +11,7 @@ iriscli distribution delegation-distr-info [flags] ``` Print help messages: -```shell +``` iriscli distribution delegation-distr-info --help ``` @@ -24,7 +24,7 @@ iriscli distribution delegation-distr-info --help ## Examples -```shell +``` iriscli distribution delegation-distr-info --address-delegator= --address-validator= ``` Example response: diff --git a/docs/cli-client/distribution/delegator-distr-info.md b/docs/cli-client/distribution/delegator-distr-info.md index f2c0077ce..cb4c501b1 100644 --- a/docs/cli-client/distribution/delegator-distr-info.md +++ b/docs/cli-client/distribution/delegator-distr-info.md @@ -2,7 +2,7 @@ ## Description -Query delegator distribution information +Query a delegator distribution information ## Usage @@ -11,18 +11,18 @@ iriscli distribution delegator-distr-info [flags] ``` Print help messages: -```shell +``` iriscli distribution delegator-distr-info --help ``` ## Unique Flags -There is no unique option. But it requires a argument: delegator address +There is no unique flag. But it requires a argument: delegator address ## Examples -```shell -iriscli distribution delegation-distr-info +``` +iriscli distribution delegator-distr-info ``` Example response: ```json diff --git a/docs/cli-client/distribution/set-withdraw-address.md b/docs/cli-client/distribution/set-withdraw-address.md index 95926ead8..6aa1140f2 100644 --- a/docs/cli-client/distribution/set-withdraw-address.md +++ b/docs/cli-client/distribution/set-withdraw-address.md @@ -2,7 +2,7 @@ ## Description -Set withdraw address of a delegator +Set withdraw address for delegator ## Usage @@ -11,17 +11,17 @@ iriscli distribution set-withdraw-addr [withdraw-addr] [flags] ``` Print help messages: -```shell +``` iriscli distribution set-withdraw-addr --help ``` ## Unique Flags -There is no unique option. But it requires a argument: new withdraw address +There is no unique flag. But it requires an argument: new withdraw address ## Examples -```shell -iriscli distribution set-withdraw-addr
--from --fee=0.004iris --chain-id= +``` +iriscli distribution set-withdraw-addr --from --fee=0.004iris --chain-id= ``` diff --git a/docs/cli-client/distribution/validator-distr-info.md b/docs/cli-client/distribution/validator-distr-info.md index d006e61ce..840b6d776 100644 --- a/docs/cli-client/distribution/validator-distr-info.md +++ b/docs/cli-client/distribution/validator-distr-info.md @@ -2,7 +2,7 @@ ## Description -Query validator distribution information +Query a validator distribution information ## Usage @@ -11,18 +11,18 @@ iriscli distribution validator-distr-info [flags] ``` Print help messages: -```shell +``` iriscli distribution validator-distr-info --help ``` ## Unique Flags -There is no unique option. But it requires a argument: validator address +There is no unique flag. But it requires an argument: validator address ## Examples -```shell +``` iriscli distribution validator-distr-info ``` Example response: diff --git a/docs/cli-client/distribution/withdraw-address.md b/docs/cli-client/distribution/withdraw-address.md index c47549c26..f3ab8030c 100644 --- a/docs/cli-client/distribution/withdraw-address.md +++ b/docs/cli-client/distribution/withdraw-address.md @@ -2,7 +2,7 @@ ## Description -Query withdraw address of a delegator +Query the withdraw address of a delegator ## Usage @@ -12,7 +12,7 @@ iriscli distribution withdraw-address [delegator address] [flags] Print help messages: -```shell +``` iriscli distribution withdraw-address --help ``` @@ -23,8 +23,8 @@ There is no unique option. But it requires a argument: delegator address ## Examples -```shell -iriscli distribution withdraw-address +``` +iriscli distribution withdraw-address ``` Example response: ```text diff --git a/docs/cli-client/distribution/withdraw-rewards.md b/docs/cli-client/distribution/withdraw-rewards.md index 98a18d59d..3b949047f 100644 --- a/docs/cli-client/distribution/withdraw-rewards.md +++ b/docs/cli-client/distribution/withdraw-rewards.md @@ -27,15 +27,15 @@ Keep in mind, don't specify the above options both. ## Examples -1. Only withdraw the delegation reward from a given validator +1. Only withdraw a delegation rewards from a given validator ``` - iriscli distribution withdraw-rewards --only-from-validator fva134mhjjyyc7mehvaay0f3d4hj8qx3ee3w3eq5nq --from mykey --fee=0.004iris --chain-id=irishub-test + iriscli distribution withdraw-rewards --only-from-validator --from --fee=0.004iris --chain-id= ``` -2. Withdraw all delegation reward of a delegator +2. Withdraw all delegation rewards of a delegator ``` - iriscli distribution withdraw-rewards --from mykey --fee=0.004iris --chain-id=irishub-test + iriscli distribution withdraw-rewards --from --fee=0.004iris --chain-id= ``` -3. If the delegator is a onwer of a validator, withdraw all delegation reward and validator reward: +3. If the delegator is a onwer of a validator, withdraw all delegation rewards and validator commmission rewards: ``` - iriscli distribution withdraw-rewards --is-validator=true --from mykey --fee=0.004iris --chain-id=irishub-test + iriscli distribution withdraw-rewards --is-validator=true --from --fee=0.004iris --chain-id= ``` \ No newline at end of file diff --git a/docs/cli-client/stake/redelegate.md b/docs/cli-client/stake/redelegate.md index 0e4813f2a..c594e79c7 100644 --- a/docs/cli-client/stake/redelegate.md +++ b/docs/cli-client/stake/redelegate.md @@ -2,7 +2,7 @@ ## Introduction -Redelegate transfer delegation from one validator to another one. +Transfer delegation from one validator to another one. ## Usage @@ -25,7 +25,7 @@ iriscli stake redelegate --help | --shares-amount | float | false | 0.0 | Amount of source-shares to either unbond or redelegate as a positive integer or decimal | | --shares-percent | float | false | 0.0 | Percent of source-shares to either unbond or redelegate as a positive integer or decimal >0 and <=1 | -Users must specify the redeleagte amount. There two options can do this: `--shares-amount` or `--shares-percent`. Keep in mind, don't specify them both. +Users must specify the redeleagtion token amount. There two options can do this: `--shares-amount` or `--shares-percent`. Keep in mind, don't specify both of them. ## Examples diff --git a/docs/cli-client/stake/unbond.md b/docs/cli-client/stake/unbond.md index eac8b028e..244973a94 100644 --- a/docs/cli-client/stake/unbond.md +++ b/docs/cli-client/stake/unbond.md @@ -2,7 +2,7 @@ ## Introduction -Unbond shares from a validator +Unbond tokens from a validator ## Usage @@ -24,7 +24,7 @@ iriscli stake unbond --help | --shares-amount | float | false | 0.0 | Amount of source-shares to either unbond or redelegate as a positive integer or decimal | | --shares-percent | float | false | 0.0 | Percent of source-shares to either unbond or redelegate as a positive integer or decimal >0 and <=1 | -Users must specify the unbond amount. There two options can do this: `--shares-amount` or `--shares-percent`. Keep in mind, don't specify them both. +Users must specify the unbond amount. There two options can do this: `--shares-amount` or `--shares-percent`. Keep in mind, don't specify both of them. ## Examples diff --git a/docs/cli-client/stake/unjail.md b/docs/cli-client/stake/unjail.md index 2dd3d4368..7a29eaa57 100644 --- a/docs/cli-client/stake/unjail.md +++ b/docs/cli-client/stake/unjail.md @@ -2,7 +2,7 @@ ## Introduction -Unjail validator previously jailed for downtime +Unjail validator which may be jailed previously for downtime ## Usage diff --git a/docs/zh/cli-client/README.md b/docs/zh/cli-client/README.md index c4586a191..6f280cdca 100644 --- a/docs/zh/cli-client/README.md +++ b/docs/zh/cli-client/README.md @@ -40,7 +40,7 @@ 每个发送交易的命令都包含上表中的flags,同时不同交易的命令还可能会有自己独有的flags。 -## Command list +## 模块列表 1. [bank command](./bank/README.md) 2. [distribution command](./distribution/README.md)