cln: improve help outputs

This commit is contained in:
openoms 2021-09-22 16:06:37 +01:00
parent 90421b1c3b
commit 8face72273
No known key found for this signature in database
GPG Key ID: 5BFB77609B081B65
6 changed files with 50 additions and 41 deletions

View File

@ -2,18 +2,20 @@
# command info
if [ $# -eq 0 ] || [ "$1" = "-h" ] || [ "$1" = "-help" ]; then
echo "# ---------------------------------------------------"
echo "# CLN RESCUE FILE (tar.gz of complete cln directory)"
echo "# ---------------------------------------------------"
echo "# cln.backup.sh cln-export"
echo "# cln.backup.sh cln-export-gui"
echo "# cln.backup.sh cln-import [file]"
echo "# cln.backup.sh cln-import-gui [setup|production] [?resultfile]"
echo "# ---------------------------------------------------"
echo "# SEED WORDS"
echo "# ---------------------------------------------------"
echo "# cln.backup.sh seed-export-gui [lndseeddata]"
echo "# cln.backup.sh seed-import-gui [resultfile]"
echo
echo "---------------------------------------------------"
echo "CLN RESCUE FILE (tar.gz of complete cln directory)"
echo "---------------------------------------------------"
echo "cln.backup.sh cln-export"
echo "cln.backup.sh cln-export-gui"
echo "cln.backup.sh cln-import [file]"
echo "cln.backup.sh cln-import-gui [setup|production] [?resultfile]"
echo "---------------------------------------------------"
echo "SEED WORDS"
echo "---------------------------------------------------"
echo "cln.backup.sh seed-export-gui [lndseeddata]"
echo "cln.backup.sh seed-import-gui [resultfile]"
echo
exit 1
fi

View File

@ -9,26 +9,26 @@
if [ $# -lt 1 ] || [ "$1" = "-h" ] || [ "$1" = "-help" ]||\
! echo "$@" | grep -Eq "new|seed|unlock|lock|encrypt|decrypt|autounlock-on|autounlock-off|change-password" ;then
echo
echo "# create new wallet or import seed"
echo "# unlock/lock, encrypt, decrypt, set autounlock or change password for the hsm_secret"
echo "Create new wallet or import seed"
echo "Unlock/lock, encrypt, decrypt, set autounlock or change password for the hsm_secret"
echo
echo "# usage:"
echo "# Create new wallet"
echo "# cln.hsmtool.sh [new] [mainnet|testnet|signet] [?seedPassword]"
echo "# cln.hsmtool.sh [new-force] [mainnet|testnet|signet] [?seedPassword]"
echo "# There will be no seedPassword(passphrase) used by default"
echo "# new-force will delete any old wallet and will work without dialog"
echo "Usage:"
echo "Create new wallet:"
echo "cln.hsmtool.sh [new] [mainnet|testnet|signet] [?seedPassword]"
echo "cln.hsmtool.sh [new-force] [mainnet|testnet|signet] [?seedPassword]"
echo "There will be no seedPassword(passphrase) used by default"
echo "new-force will delete any old wallet and will work without dialog"
echo
echo "# cln.hsmtool.sh [seed] [mainnet|testnet|signet] [\"space-separated-seed-words\"] [?seedPassword]"
echo "# cln.hsmtool.sh [seed-force] [mainnet|testnet|signet] [\"space-separated-seed-words\"] [?seedPassword]"
echo "# the new hsm_secret will be not encrypted if no NewPassword is given"
echo "# seed-force will delete any old wallet and will work without dialog"
echo "cln.hsmtool.sh [seed] [mainnet|testnet|signet] [\"space-separated-seed-words\"] [?seedPassword]"
echo "cln.hsmtool.sh [seed-force] [mainnet|testnet|signet] [\"space-separated-seed-words\"] [?seedPassword]"
echo "The new hsm_secret will be not encrypted if no NewPassword is given"
echo "seed-force will delete any old wallet and will work without dialog"
echo
echo "# cln.hsmtool.sh [unlock|lock] <mainnet|testnet|signet>"
echo "# cln.hsmtool.sh [encrypt|decrypt] <mainnet|testnet|signet>"
echo "# cln.hsmtool.sh [autounlock-on|autounlock-off] <mainnet|testnet|signet>"
echo "cln.hsmtool.sh [unlock|lock] <mainnet|testnet|signet>"
echo "cln.hsmtool.sh [encrypt|decrypt] <mainnet|testnet|signet>"
echo "cln.hsmtool.sh [autounlock-on|autounlock-off] <mainnet|testnet|signet>"
echo
echo "# cln.hsmtool.sh [change-password] <mainnet|testnet|signet> <NewPassword>"
echo "cln.hsmtool.sh [change-password] <mainnet|testnet|signet> <NewPassword>"
echo
exit 1
fi

View File

@ -1,8 +1,14 @@
#!/bin/bash
# script to set up or update the CLN systemd service
# usage:
# /home/admin/config.scripts/cln.install-service.sh $CHAIN
# help
if [ "$1" = "-h" ]||[ "$1" = "--help" ];then
echo
echo "Script to set up or update the C-lightning systemd service"
echo "Usage:"
echo "/home/admin/config.scripts/cln.install-service.sh <mainnet|testnet|signet>"
echo
exit 1
fi
# source <(/home/admin/config.scripts/network.aliases.sh getvars cln <mainnet|testnet|signet>)
source <(/home/admin/config.scripts/network.aliases.sh getvars cln $1)

View File

@ -16,11 +16,11 @@ source /mnt/hdd/raspiblitz.conf
if [ $# -eq 0 ]||[ "$1" = "-h" ]||[ "$1" = "--help" ];then
echo
echo "C-lightning install script"
echo "the default version is: $CLVERSION"
echo "setting up on ${chain}net unless otherwise specified"
echo "The default version is: $CLVERSION"
echo "Setting up on ${chain}net unless otherwise specified"
echo "mainnet / testnet / signet instances can run parallel"
echo
echo "usage:"
echo "Usage:"
echo "cln.install.sh on <mainnet|testnet|signet>"
echo "cln.install.sh off <mainnet|testnet|signet> <purge>"
echo "cln.install.sh [update <version>|testPR <PRnumber>]"

View File

@ -7,12 +7,11 @@ CLRESTVERSION="v0.5.1"
if [ $# -eq 0 ]||[ "$1" = "-h" ]||[ "$1" = "--help" ];then
echo
echo "C-lightning-REST install script"
echo "the default version is: $CLRESTVERSION"
echo "setting up on ${chain}net unless otherwise specified"
echo "The default version is: $CLRESTVERSION"
echo "mainnet | testnet | signet instances can run parallel"
echo "the same macaroon and certs will be used for the parallel networks"
echo "The same macaroon and certs will be used for the parallel networks"
echo
echo "usage:"
echo "Usage:"
echo "cln.rest.sh [on|off|connect] <mainnet|testnet|signet>"
echo
exit 1

View File

@ -2,9 +2,11 @@
# command info
if [ "$1" = "-h" ] || [ "$1" = "-help" ]; then
echo "small config script to set alias of the C-lightning node "
echo "cln.setname.sh [mainnet|testnet|signet] [?newName]"
exit 1
echo
echo "Config script to set the alias of the C-lightning node"
echo "cln.setname.sh [mainnet|testnet|signet] [?newName]"
echo
exit 1
fi
# 1. parameter [?newName]