From a56582bf2add721d729384cd209ad28908569d40 Mon Sep 17 00:00:00 2001 From: NRK Date: Wed, 11 Aug 2021 16:09:41 +0600 Subject: [PATCH] use cat << EOF to print usage and version --- sxbm | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/sxbm b/sxbm index d06bdda..1578e2c 100755 --- a/sxbm +++ b/sxbm @@ -43,8 +43,9 @@ die() { } usage() { - printf "Usage: $APPNAME []\n" - printf " + cat << EOF +Usage: $APPNAME [] + COMMANDS: add [title] [+tags] ls|list [-s|--strict] [-c|--disable-colors] [title] [+tags] @@ -52,13 +53,17 @@ COMMANDS: rm|remove edit -h|--help print this text and exit - -v|--version print the version and exit\n\n" + -v|--version print the version and exit + +EOF } version() { - printf "$APPNAME $VERSION\n" - printf "GPLv3 license\n" - printf "https://github.com/n-r-k/sxbm\n" + cat << EOF +$APPNAME $VERSION +GPLv3 license +https://github.com/n-r-k/sxbm +EOF } bm_add() {