]> git.ozlabs.org Git - petitboot/commitdiff
utils/pbconsole: Use here-document for usage text
authorJeremy Kerr <jk@ozlabs.org>
Mon, 20 May 2013 02:42:08 +0000 (10:42 +0800)
committerJeremy Kerr <jk@ozlabs.org>
Mon, 20 May 2013 02:42:08 +0000 (10:42 +0800)
Allows for cleaner usage message in the source.

Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
utils/pb-console

index c96ac9825d870e3039fb24d86706b50e4c988871..00b25acf44c8d996bafaf178673805766a0f88b0 100644 (file)
@@ -10,12 +10,14 @@ shell=sh
 detach=0
 
 usage() {
 detach=0
 
 usage() {
-       echo "pb-console [OPTIONS] console_dev" >&2
-       echo "OPTIONS" >&2
-       echo "     -d, --detach" >&2
-       echo "             Start in a detached (background) state." >&2
-       echo "     -h, --help" >&2
-       echo "             Print a help message." >&2
+       cat >&2 <<EOF
+pb-console [OPTIONS] console_dev
+OPTIONS
+     -d, --detach
+             Start in a detached (background) state.
+     -h, --help
+             Print a help message.
+EOF
        exit 1
 }
 
        exit 1
 }