From a15fd48016014249a13db7a437b5e4f5937f6158 Mon Sep 17 00:00:00 2001 From: "Jason St. John" Date: Fri, 8 Nov 2013 02:53:33 -0500 Subject: Improve --help switch output for pacman contrib and pacman scripts MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Unify the formatting of the --help switch for pacman utils, if it exists. All of the pacman utils will now output help text using the following format: util-name (pacman) v one line description of util's purpose Usage: util-name [options] -b, --bar whatever --bar does -f, --foo whatever --foo does -h, --help display this help message Reported-by: Karol Błażewicz Signed-off-by: Jason St. John --- contrib/pacsysclean.sh.in | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'contrib/pacsysclean.sh.in') diff --git a/contrib/pacsysclean.sh.in b/contrib/pacsysclean.sh.in index 37219ab5..36319215 100644 --- a/contrib/pacsysclean.sh.in +++ b/contrib/pacsysclean.sh.in @@ -8,9 +8,12 @@ declare -r myver='@PACKAGE_VERSION@' PACMAN_OPTS= usage() { - echo "$myname - Sort installed packages by increasing installed size." + echo "${myname} (pacman) v${myver}" echo - echo "Usage: $myname [options]" + echo "Sort installed packages by increasing installed size. Useful for" + echo "system clean-up." + echo + echo "Usage: ${myname} [options]" echo echo "Options:" echo " -o Specify custom pacman query options (e.g., dt)" @@ -22,7 +25,6 @@ version() { echo 'Copyright (C) 2011 Eric Bélanger ' } - if [ -n "$1" ]; then case "$1" in -o) PACMAN_OPTS="${2}" ;; -- cgit v1.2.3