Skip to content

Commit

Permalink
changed most namadaw functions
Browse files Browse the repository at this point in the history
  • Loading branch information
bengtlofgren committed Jan 10, 2024
1 parent 258df84 commit 0e62742
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 26 deletions.
4 changes: 2 additions & 2 deletions packages/docs/pages/introduction/quick-start.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,15 @@ This should sync your node to the ledger and will take a while (depending on you
First you will need an implicit account in order to receive tokens. You can generate one with:

```shell copy
namadaw address gen --alias <your-go-to-alias>
namadaw gen --alias <your-go-to-alias>
```

For the remainder of this introduction, let's assume your go-to alias is `stanley`.

This will generate a new account and store it in the default keychain. You can see the account with:

```shell copy
namadaw address list
namadaw list --addr
```

{/* #TODO: ADD some output */}
Expand Down
2 changes: 1 addition & 1 deletion packages/docs/pages/operators/ibc.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ cp ./target/release/hermes /usr/local/bin/
### Create the relayer account
On each chain, there must be a `relayer` account. The alias should be the same as `chains.key_name` in the config. On a namada chain, this can be done by running
```bash copy
namadaw key gen --alias relayer
namadaw gen key --alias relayer
```

This will generate a key for the relayer account. The key will be stored in the `wallet.toml` that is found in the [base directory](./ledger/base-directory.mdx) of the node, inside the `chain-id` folder. For example, if the `chain-id` is `namada-test.0a4c6786dbda39f786`, the `wallet.toml` will be found in `$HOME/.local/share/namada/namada-test.0a4c6786dbda39f786/wallet.toml` (on a ubuntu machine where `base-dir` has not been set up properly).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ This can be done through the namada cli:

```bash
ALIAS="<your-key-alias>"
namadaw --pre-genesis key gen --alias $ALIAS
namadaw --pre-genesis gen --alias $ALIAS
```

After the user has entered their passwords and written down their mnemonic phrase, the namada cli will save the keys to the `pre-genesis` folder inside the [base directory](../../ledger/base-directory.mdx).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ The user must first generate a key pair for their validator account.

```bash copy
KEY_ALIAS="aliace"
namada wallet key gen --alias $KEY_ALIAS
namada wallet gen --alias $KEY_ALIAS
```

Now choose a name for your validator:
Expand Down
22 changes: 9 additions & 13 deletions packages/docs/pages/users/transparent-accounts.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,11 @@ Note the use of the placeholder `keysha` for the key parameter. This is a compl

```shell copy
KEY_ALIAS="keysha"
namada wallet key gen --alias $KEY_ALIAS
namada wallet gen --alias $KEY_ALIAS
```

<Callout type="info">
The derived implicit address shares the same `keysha` alias. The previous command has the same effect as `namada wallet address gen --alias keysha`.
The derived implicit address shares the same `keysha` alias. The previous command has the same effect as `namada wallet gen --alias keysha`.
</Callout>

By default, the keys are stored encrypted.
Expand All @@ -43,7 +43,7 @@ Namada wallet supports keypair generation using a [mnemonic code](https://github
To generate a keypair for a default path use
```shell copy
KEY_ALIAS="keysha"
namada wallet key gen --alias $KEY_ALIAS --hd-path default
namada wallet gen --alias $KEY_ALIAS --hd-path default
```

<Callout type="info">
Expand All @@ -67,7 +67,7 @@ namada wallet key restore --alias keysha --hd-path default
### List all known keys

```shell copy
namada wallet key list
namada wallet list --keys
```

## Manage addresses
Expand All @@ -76,32 +76,28 @@ namada wallet key list
To manage addresses, similar to keys, various sub-commands are available:

```shell copy
namada wallet address
namada wallet --help
```

### Generate an implicit address

Let's call the implicit address `accountant`:
```shell copy
namada wallet address gen --alias accountant
namada wallet gen --alias accountant
```

<Callout type="info">
Note that this will also generate and save a key from which the address was derived and save it under the same `accountant` alias. Thus, this command has the same effect as `namada wallet key gen --alias accountant`.
</Callout>

```shell copy
namada wallet address gen --alias keysha --hd-path default
namada wallet gen --alias keysha --hd-path default
```
generates an address using a [mnemonic code](https://github.com/bitcoin/bips/blob/master/bip-0039.mediawiki) and [HD derivation path](https://github.com/bitcoin/bips/blob/master/bip-0044.mediawiki).

### Restore the address

```shell copy
namada wallet address restore --alias keysha --hd-path default
namada wallet derive --alias keysha --hd-path default
```
### List all known addresses

```shell copy
namada wallet address list
namada wallet list --addr
```
Original file line number Diff line number Diff line change
Expand Up @@ -16,21 +16,15 @@ Before creating an account, a user must generate at least one cryptographic `key

The following method will generate such a key:
```shell
namadaw key gen \
namadaw gen \
--alias my-key1
```
A second key can be generated as well (which will be useful for multisigs):
```shell
namadaw key gen \
namadaw gen \
--alias my-key2
```

An implicit address can also be generated:
```shell
namadaw address gen \
--alias my-address
```

Accounts on Namada are initialised through the following method:

**Non-multisig account (single signer)**
Expand Down

0 comments on commit 0e62742

Please sign in to comment.