Implement generate-only option for commands that create txs

The new CLI flag builds an unsigned transaction and writes it to STDOUT.
Likewise, REST clients can now append generate_only=true to a request's
query arguments list and expect a JSON response carrying the unsigned
transaction.

Closes: #966
This commit is contained in:
Alessio Treglia
2018-09-04 02:32:05 +02:00
parent 7f1b06a724
commit 86395809cb
22 changed files with 270 additions and 30 deletions
+11
View File
@@ -139,6 +139,17 @@ gaiacli send \
--dry-run
```
Furthermore, you can build a transaction and print its JSON format to STDOUT by appending `--generate-only` to the list of the command line arguments:
```bash
gaiacli send \
--amount=10faucetToken \
--chain-id=<chain_id> \
--name=<key_name> \
--to=<destination_cosmosaccaddr> \
--generate-only
```
### Staking
#### Set up a Validator