Skip to content

Commit

Permalink
Updated docs to reflect bech32 default
Browse files Browse the repository at this point in the history
The manpage did not specify the name of the named parameter (addresstype).
It does now.

Fixed manpage grammar errors.

Signed-off-by: Mark Beckwith <[email protected]>
  • Loading branch information
wythe authored and rustyrussell committed Jul 23, 2018
1 parent 231f14e commit 369bd27
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
12 changes: 6 additions & 6 deletions doc/lightning-newaddr.7
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
.\" Title: lightning-newaddr
.\" Author: [see the "AUTHOR" section]
.\" Generator: DocBook XSL Stylesheets v1.79.1 <http://docbook.sf.net/>
.\" Date: 04/26/2018
.\" Date: 07/23/2018
.\" Manual: \ \&
.\" Source: \ \&
.\" Language: English
.\"
.TH "LIGHTNING\-NEWADDR" "7" "04/26/2018" "\ \&" "\ \&"
.TH "LIGHTNING\-NEWADDR" "7" "07/23/2018" "\ \&" "\ \&"
.\" -----------------------------------------------------------------
.\" * Define some portability stuff
.\" -----------------------------------------------------------------
Expand All @@ -31,22 +31,22 @@
lightning-newaddr \- Command for generating a new address to be used by c\-lightning\&.
.SH "SYNOPSIS"
.sp
\fBnewaddr\fR [ \fIp2sh\-segwit\fR | \fIbech32\fR ]
\fBnewaddr\fR [ \fIaddresstype\fR ]
.SH "DESCRIPTION"
.sp
The \fBnewaddr\fR RPC command generates a new address which can subsequently be used to fund channels managed by the c\-lightning node\&.
.sp
The funding transaction needs to be confirmed before funds can be used\&.
.sp
The optional parameter specifies the type of address wanted i\&.e\&. p2sh\-segwit (e\&.g\&. 2MxaozoqWwiUcuD9KKgUSrLFDafLqimT9Ta on bitcoin testnet or 3MZxzq3jBSKNQ2e7dzneo9hy4FvNzmMmt3 on bitcoin mainnet) or bech32 (e\&.g\&. tb1qu9j4lg5f9rgjyfhvfd905vw46eg39czmktxqgg on bitcoin testnet or bc1qwqdg6squsna38e46795at95yu9atm8azzmyvckulcc7kytlcckxswvvzej on bitcoin mainnet)\&.
\fIaddresstype\fR specifies the type of address wanted; i\&.e\&. p2sh\-segwit (e\&.g\&. 2MxaozoqWwiUcuD9KKgUSrLFDafLqimT9Ta on bitcoin testnet or 3MZxzq3jBSKNQ2e7dzneo9hy4FvNzmMmt3 on bitcoin mainnet) or bech32 (e\&.g\&. tb1qu9j4lg5f9rgjyfhvfd905vw46eg39czmktxqgg on bitcoin testnet or bc1qwqdg6squsna38e46795at95yu9atm8azzmyvckulcc7kytlcckxswvvzej on bitcoin mainnet)\&.
.sp
If not specified the address generated is p2sh\-segwit\&.
If not specified the address generated is bech32\&.
.SH "RETURN VALUE"
.sp
On success, a new address will be returned\&.
.SH "ERRORS"
.sp
If a non recognized address type is requested an error message will be returned
If an unrecognized address type is requested an error message will be returned\&.
.SH "AUTHOR"
.sp
Felix <fixone@gmail\&.com> is mainly responsible\&.
Expand Down
8 changes: 4 additions & 4 deletions doc/lightning-newaddr.7.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ be used by c-lightning.

SYNOPSIS
--------
*newaddr* [ 'p2sh-segwit' | 'bech32' ]
*newaddr* [ 'addresstype' ]

DESCRIPTION
-----------
Expand All @@ -18,21 +18,21 @@ subsequently be used to fund channels managed by the c-lightning node.

The funding transaction needs to be confirmed before funds can be used.

The optional parameter specifies the type of address wanted i.e.
'addresstype' specifies the type of address wanted; i.e.
p2sh-segwit (e.g. 2MxaozoqWwiUcuD9KKgUSrLFDafLqimT9Ta on bitcoin testnet
or 3MZxzq3jBSKNQ2e7dzneo9hy4FvNzmMmt3 on bitcoin mainnet) or bech32
(e.g. tb1qu9j4lg5f9rgjyfhvfd905vw46eg39czmktxqgg on bitcoin testnet or
bc1qwqdg6squsna38e46795at95yu9atm8azzmyvckulcc7kytlcckxswvvzej on bitcoin mainnet).

If not specified the address generated is p2sh-segwit.
If not specified the address generated is bech32.

RETURN VALUE
------------
On success, a new address will be returned.

ERRORS
------
If a non recognized address type is requested an error message will be returned
If an unrecognized address type is requested an error message will be returned.

AUTHOR
------
Expand Down
2 changes: 1 addition & 1 deletion wallet/walletrpc.c
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ static void json_newaddr(struct command *cmd, const char *buffer UNUSED,
static const struct json_command newaddr_command = {
"newaddr",
json_newaddr,
"Get a new {bech32, p2sh-segwit} address to fund a channel", false,
"Get a new {bech32, p2sh-segwit} address to fund a channel (default is bech32)", false,
"Generates a new address that belongs to the internal wallet. Funds sent to these addresses will be managed by lightningd. Use `withdraw` to withdraw funds to an external wallet."
};
AUTODATA(json_command, &newaddr_command);
Expand Down

0 comments on commit 369bd27

Please sign in to comment.