Skip to content

Commit

Permalink
generateHelpDocs filters trailing space from text
Browse files Browse the repository at this point in the history
- Change the generateHelpDocs script to remove trailing spaces from the
  generated help text. This prevents linting failures from
  check_trailingspaces.sh
- Remove trailing space from osnadmin_channel_postscript.md
- Regenerate the help docs with `make help-docs`

Signed-off-by: Matthew Sykes <sykesmat@us.ibm.com>
  • Loading branch information
sykesm committed Jan 27, 2021
1 parent 06d5ad5 commit a7ef393
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 24 deletions.
34 changes: 17 additions & 17 deletions docs/source/commands/osnadminchannel.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Channel actions
Flags:
--help Show context-sensitive help (also try
--help-long and --help-man).
-o, --orderer-address=ORDERER-ADDRESS
-o, --orderer-address=ORDERER-ADDRESS
Admin endpoint of the OSN
--ca-file=CA-FILE Path to file containing PEM-encoded TLS CA
certificate(s) for the OSN
Expand All @@ -39,7 +39,7 @@ Flags:
OSN
Subcommands:
channel join --channelID=CHANNEL-ID --config-block=CONFIG-BLOCK
channel join --channelID=CHANNELID --config-block=CONFIG-BLOCK
Join an Ordering Service Node (OSN) to a channel. If the channel does not
yet exist, it will be created.
Expand All @@ -48,22 +48,22 @@ Subcommands:
channel-id flag is set, more detailed information will be provided for that
channel.
channel remove --channelID=CHANNEL-ID
channel remove --channelID=CHANNELID
Remove an Ordering Service Node (OSN) from a channel.
```


## osnadmin channel join
```
usage: osnadmin channel join --channelID=CHANNEL-ID --config-block=CONFIG-BLOCK
usage: osnadmin channel join --channelID=CHANNELID --config-block=CONFIG-BLOCK
Join an Ordering Service Node (OSN) to a channel. If the channel does not yet
exist, it will be created.
Flags:
--help Show context-sensitive help (also try
--help-long and --help-man).
-o, --orderer-address=ORDERER-ADDRESS
-o, --orderer-address=ORDERER-ADDRESS
Admin endpoint of the OSN
--ca-file=CA-FILE Path to file containing PEM-encoded TLS CA
certificate(s) for the OSN
Expand All @@ -73,8 +73,8 @@ Flags:
--client-key=CLIENT-KEY Path to file containing PEM-encoded private key
to use for mutual TLS communication with the
OSN
-c, --channelID=CHANNEL-ID Channel ID
-b, --config-block=CONFIG-BLOCK
-c, --channelID=CHANNELID Channel ID
-b, --config-block=CONFIG-BLOCK
Path to the file containing an up-to-date
config block for the channel
```
Expand All @@ -90,7 +90,7 @@ flag is set, more detailed information will be provided for that channel.
Flags:
--help Show context-sensitive help (also try
--help-long and --help-man).
-o, --orderer-address=ORDERER-ADDRESS
-o, --orderer-address=ORDERER-ADDRESS
Admin endpoint of the OSN
--ca-file=CA-FILE Path to file containing PEM-encoded TLS CA
certificate(s) for the OSN
Expand All @@ -100,20 +100,20 @@ Flags:
--client-key=CLIENT-KEY Path to file containing PEM-encoded private key
to use for mutual TLS communication with the
OSN
-c, --channelID=CHANNEL-ID Channel ID
-c, --channelID=CHANNELID Channel ID
```


## osnadmin channel remove
```
usage: osnadmin channel remove --channelID=CHANNEL-ID
usage: osnadmin channel remove --channelID=CHANNELID
Remove an Ordering Service Node (OSN) from a channel.
Flags:
--help Show context-sensitive help (also try
--help-long and --help-man).
-o, --orderer-address=ORDERER-ADDRESS
-o, --orderer-address=ORDERER-ADDRESS
Admin endpoint of the OSN
--ca-file=CA-FILE Path to file containing PEM-encoded TLS CA
certificate(s) for the OSN
Expand All @@ -123,7 +123,7 @@ Flags:
--client-key=CLIENT-KEY Path to file containing PEM-encoded private key
to use for mutual TLS communication with the
OSN
-c, --channelID=CHANNEL-ID Channel ID
-c, --channelID=CHANNELID Channel ID
```

## Example Usage
Expand All @@ -132,7 +132,7 @@ Flags:

Here's an example of the `osnadmin channel join` command.

* Create and join a sample channel `mychannel` defined by the application channel genesis
* Create and join a sample channel `mychannel` defined by the application channel genesis
block contained in file `mychannel-genesis-block.pb`. Use the orderer admin endpoint
at `orderer.example.com:9443`.

Expand Down Expand Up @@ -162,7 +162,7 @@ Here are some examples of the `osnadmin channel list` command.
system channel (if one exists) and all of the application channels.

```
osnadmin channel list -o orderer.example.com:9443 --ca-file $CA_FILE --client-cert $CLIENT_CERT --client-key $CLIENT_KEY
osnadmin channel list -o orderer.example.com:9443 --ca-file $CA_FILE --client-cert $CLIENT_CERT --client-key $CLIENT_KEY
Status: 200
{
Expand All @@ -177,7 +177,7 @@ Here are some examples of the `osnadmin channel list` command.
```

Status 200 and the list of channels are returned.
Status 200 and the list of channels are returned.

* Using the `--channelID` flag to list more details for `mychannel`.

Expand All @@ -195,7 +195,7 @@ Here are some examples of the `osnadmin channel list` command.
```

Status 200 and the details of the channels are returned.
Status 200 and the details of the channels are returned.

### osnadmin channel remove example

Expand All @@ -209,6 +209,6 @@ Here's an example of the `osnadmin channel remove` command.
Status: 204
```

Status 204 is returned upon successful removal of a channel.
Status 204 is returned upon successful removal of a channel.

<a rel="license" href="http://creativecommons.org/licenses/by/4.0/"><img alt="Creative Commons License" style="border-width:0" src="https://i.creativecommons.org/l/by/4.0/88x31.png" /></a><br />This work is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/4.0/">Creative Commons Attribution 4.0 International License</a>.
10 changes: 5 additions & 5 deletions docs/wrappers/osnadmin_channel_postscript.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

Here's an example of the `osnadmin channel join` command.

* Create and join a sample channel `mychannel` defined by the application channel genesis
* Create and join a sample channel `mychannel` defined by the application channel genesis
block contained in file `mychannel-genesis-block.pb`. Use the orderer admin endpoint
at `orderer.example.com:9443`.

Expand Down Expand Up @@ -34,7 +34,7 @@ Here are some examples of the `osnadmin channel list` command.
system channel (if one exists) and all of the application channels.

```
osnadmin channel list -o orderer.example.com:9443 --ca-file $CA_FILE --client-cert $CLIENT_CERT --client-key $CLIENT_KEY
osnadmin channel list -o orderer.example.com:9443 --ca-file $CA_FILE --client-cert $CLIENT_CERT --client-key $CLIENT_KEY
Status: 200
{
Expand All @@ -49,7 +49,7 @@ Here are some examples of the `osnadmin channel list` command.
```

Status 200 and the list of channels are returned.
Status 200 and the list of channels are returned.

* Using the `--channelID` flag to list more details for `mychannel`.

Expand All @@ -67,7 +67,7 @@ Here are some examples of the `osnadmin channel list` command.
```

Status 200 and the details of the channels are returned.
Status 200 and the details of the channels are returned.

### osnadmin channel remove example

Expand All @@ -81,6 +81,6 @@ Here's an example of the `osnadmin channel remove` command.
Status: 204
```

Status 204 is returned upon successful removal of a channel.
Status 204 is returned upon successful removal of a channel.

<a rel="license" href="http://creativecommons.org/licenses/by/4.0/"><img alt="Creative Commons License" style="border-width:0" src="https://i.creativecommons.org/l/by/4.0/88x31.png" /></a><br />This work is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/4.0/">Creative Commons Attribution 4.0 International License</a>.
2 changes: 1 addition & 1 deletion docs/wrappers/peer_lifecycle_chaincode_postscript.md
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ also outputs which organizations have approved the chaincode definition. If an
organization has approved the chaincode definition specified in the command, the
command will return a value of true. You can use this command to learn whether enough
channel members have approved a chaincode definition to meet the
`Application/Channel/Endorsement` policy (a majority by default) before the
`/Channel/Application/Endorsement` policy (a majority by default) before the
definition can be committed to a channel.
* Here is an example of the `peer lifecycle chaincode checkcommitreadiness` command,
Expand Down
2 changes: 1 addition & 1 deletion scripts/generateHelpDocs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ generateHelpText(){
## $x
\`\`\`
$($x --help 2>&1)
$($x --help 2>&1 | sed -E 's/[[:space:]]+$//g')
\`\`\`
EOF
Expand Down

0 comments on commit a7ef393

Please sign in to comment.