summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Reisner <d@falconindy.com>2011-06-07 17:39:39 +0200
committerDave Reisner <d@falconindy.com>2011-06-19 23:33:34 +0200
commit8c16b7c6f229b187bae94cc86ac8fb3df04859df (patch)
tree44be66beacf2950ab054c489ce50b1e8bce0a0da
parentb0a3e03cbec5e552698e4dbfacee6ba16313a144 (diff)
downloadmkinitcpio-8c16b7c6f229b187bae94cc86ac8fb3df04859df.tar.gz
mkinitcpio-8c16b7c6f229b187bae94cc86ac8fb3df04859df.tar.xz
mkinitcpio: declare usage as a heredoc
alphabetize the usage while we're at it
-rwxr-xr-xmkinitcpio40
1 files changed, 22 insertions, 18 deletions
diff --git a/mkinitcpio b/mkinitcpio
index 53326f0..295d194 100755
--- a/mkinitcpio
+++ b/mkinitcpio
@@ -36,24 +36,28 @@ unset GREP_OPTIONS
APPNAME=${0##*/}
-usage ()
-{
- echo "${APPNAME}: usage"
- echo " -c CONFIG Use CONFIG file. default: /etc/mkinitcpio.conf"
- echo " -k KERNELVERSION Use KERNELVERSION. default: $(uname -r)"
- echo " -s Save build directory. default: no"
- echo " -b BASEDIR Use BASEDIR. default: /"
- echo " -g IMAGE Generate a cpio image as IMAGE. default: no"
- echo " -p PRESET Build specified preset."
- echo " -m MESSAGE Print MESSAGE before passing control to init."
- echo " -n Disable colorized output messages."
- echo " -S SKIPHOOKS Skip SKIPHOOKS (comma-separated) when building the image."
- echo " -t TMPDIR Use TMPDIR as the temporary build directory."
- echo " -v Verbose output. Default: no"
- echo " -M Display modules found via autodetection."
- echo " -L List all available hooks."
- echo " -H HOOKNAME Output help for hook 'HOOKNAME'."
- echo " -h This message."
+usage() {
+ cat <<EOF
+usage: $APPNAME [options]
+
+ Options:
+ -b BASEDIR Use BASEDIR. default: /
+ -c CONFIG Use CONFIG file. default: /etc/mkinitcpio.conf
+ -g IMAGE Generate a cpio image as IMAGE. default: no
+ -H HOOKNAME Output help for hook 'HOOKNAME'.
+ -h Display this message.
+ -k KERNELVERSION Use KERNELVERSION. default: $(uname -r)
+ -L List all available hooks.
+ -M Display modules found via autodetection.
+ -n Disable colorized output messages.
+ -m MESSAGE Print MESSAGE before passing control to init.
+ -p PRESET Build specified preset from /etc/mkinitcpio.d
+ -S SKIPHOOKS Skip SKIPHOOKS (comma-separated) when building the image.
+ -s Save build directory. default: no
+ -t TMPDIR Use TMPDIR as the temporary build directory.
+ -v Verbose output. Default: no.
+
+EOF
cleanup
exit 1
}