Browse Source

* changed bin/sde-list to use a usage function instead of

the deprecated lib/sde-list.hlp


git-svn-id: svn://svn.opensde.net/opensde/opensde/trunk@21600 10447126-35f2-4685-b0cf-6dd780d3921f
misl/sde-wrapper
Alejandro Mery 17 years ago
parent
commit
85f7c3233d
2 changed files with 9 additions and 23 deletions
  1. +9
    -8
      bin/sde-list
  2. +0
    -15
      lib/sde-list.hlp

+ 9
- 8
bin/sde-list

@ -22,12 +22,18 @@ set -e
. $SDEROOT/lib/libsde.in
list_usage() {
cat <<EOT
Usage: sde list [pkg|package] [--arch <arch>]
EOT
}
sde_list_package() {
local repo=
if [ -n "$arch" -a ! -d $SDEROOT/architecture/$arch/ ]; then
echo_error "wrong architecture ($arch) specified, aborting."
sde_list_help
list_usage
return 1
fi
@ -40,11 +46,6 @@ sde_list_package() {
done | sort -k 3
}
sde_list_help() {
. $SDEROOT/lib/sde-help.in
help_command list
}
option=help
arch=
@ -65,9 +66,9 @@ done
# multiplex
case "$option" in
package|pkg) sde_list_package ;;
help) sde_list_help ;;
help) list_usage ;;
*) echo_error "Unknown discriminator '$option'."
sde_list_help
list_usage
exit 1 ;;
esac

+ 0
- 15
lib/sde-list.hlp

@ -1,15 +0,0 @@
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
#
# Filename: lib/sde-list.hlp
# Copyright (C) 2007 The OpenSDE Project
#
# More information can be found in the files COPYING and README.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License. A copy of the
# GNU General Public License can be found in the file COPYING.
# --- SDE-COPYRIGHT-NOTE-END ---
Usage: sde list [pkg|package] [--arch <arch>]

Loading…
Cancel
Save