1 #!@l_prefix@/lib/openpkg/bash |
1 #!@l_prefix@/lib/openpkg/bash |
2 ## |
2 ## |
3 ## rpmtool -- OpenPKG RPM Auxiliary Tool |
3 ## rpmtool -- OpenPKG RPM Auxiliary Tool |
4 ## Copyright (c) 2000-2007 OpenPKG Foundation e.V. <http://openpkg.net/> |
4 ## Copyright (c) 2000-2012 OpenPKG GmbH <http://openpkg.com/> |
5 ## Copyright (c) 2000-2007 Ralf S. Engelschall <http://engelschall.com/> |
|
6 ## |
5 ## |
7 ## Permission to use, copy, modify, and distribute this software for |
6 ## This software is property of the OpenPKG GmbH, DE MUC HRB 160208. |
8 ## any purpose with or without fee is hereby granted, provided that |
7 ## All rights reserved. Licenses which grant limited permission to use, |
9 ## the above copyright notice and this permission notice appear in all |
8 ## copy, modify and distribute this software are available from the |
10 ## copies. |
9 ## OpenPKG GmbH. |
11 ## |
10 ## |
12 ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED |
11 ## THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESSED OR IMPLIED |
13 ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF |
12 ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF |
14 ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. |
13 ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. |
15 ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR |
14 ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR |
16 ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
15 ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
17 ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT |
16 ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT |
33 echo "$0:Hint: run \`$0 -h' for usage" 1>&2 |
32 echo "$0:Hint: run \`$0 -h' for usage" 1>&2 |
34 exit 1 |
33 exit 1 |
35 fi |
34 fi |
36 if [ ".$1" = ".-h" -o ".$1" = ".--help" ]; then |
35 if [ ".$1" = ".-h" -o ".$1" = ".--help" ]; then |
37 echo "This is $prog_name, version $prog_vers ($prog_date)" |
36 echo "This is $prog_name, version $prog_vers ($prog_date)" |
38 echo "Copyright (c) 2000-2004 Ralf S. Engelschall <rse@engelschall.com>" |
37 echo "Copyright (c) 2000-2012 OpenPKG GmbH <http://openpkg.com/>" |
39 echo '' |
38 echo '' |
40 echo "Usage: $prog_name [<options>] [<cmd-name> [<cmd-options>] [<cmd-args>]]" |
39 echo "Usage: $prog_name [<options>] [<cmd-name> [<cmd-options>] [<cmd-args>]]" |
41 echo '' |
40 echo '' |
42 echo 'Available global <options>:' |
41 echo 'Available global <options>:' |
43 echo ' -d, --debug enable internal debugging' |
42 echo ' -d, --debug enable internal debugging' |
1086 msg ) |
1085 msg ) |
1087 # optionally beep before message |
1086 # optionally beep before message |
1088 if [ ".$opt_b" = .yes ]; then |
1087 if [ ".$opt_b" = .yes ]; then |
1089 echo . | awk '{ printf("%c", 7); }' |
1088 echo . | awk '{ printf("%c", 7); }' |
1090 fi |
1089 fi |
|
1090 |
|
1091 # determine title of message |
1091 title="" |
1092 title="" |
1092 case $opt_t in |
1093 case $opt_t in |
1093 info ) title="-------" ;; |
1094 info ) title="-------" ;; |
1094 notice ) title="Notice-" ;; |
1095 notice ) title="Notice-" ;; |
1095 warn ) title="Warning" ;; |
1096 warn ) title="Warning" ;; |
1112 CORE|BASE ) |
1113 CORE|BASE ) |
1113 ;; |
1114 ;; |
1114 PLUS ) |
1115 PLUS ) |
1115 echo "set +x" |
1116 echo "set +x" |
1116 ( echo "This OpenPKG package is of class PLUS." |
1117 ( echo "This OpenPKG package is of class PLUS." |
1117 echo "It is still in a QUALITY ASSURANCE state," |
1118 echo "This means it is still in extended QUALITY ASSURANCE state." |
1118 echo "therefore it is NOT ready for careless use." |
1119 echo "Hence it is still NOT ready for careless use." |
1119 echo "Do not use it in critical production environments." |
1120 echo "Do not use it in critical production environments." |
1120 echo "This software might still be unstable at runtime." |
1121 echo "It might be still potentially unstable under run-time." |
1121 ) | sh $prog_path msg -r -t notice | sed -e 's;^;echo ";' -e 's;$;";' |
1122 ) | sh $prog_path msg -r -t notice | sed -e 's;^;echo ";' -e 's;$;";' |
1122 echo "set -x" |
1123 echo "set -x" |
1123 ;; |
1124 ;; |
1124 EVAL ) |
1125 EVAL ) |
1125 echo "set +x" |
1126 echo "set +x" |
1126 ( echo "This OpenPKG package is of class EVAL." |
1127 ( echo "This OpenPKG package is of class EVAL." |
1127 echo "It is still in a EVALUATION and QA state," |
1128 echo "This means it is still in EVALUATION and QUALITY ASSURANCE state." |
1128 echo "therefore it is NOT ready for general use." |
1129 echo "Hence it is still NOT ready for general use." |
1129 echo "Do not use it in production environments." |
1130 echo "Do not use it in production environments." |
1130 echo "It might be unstable or incompletely packaged." |
1131 echo "It might be unstable under run-time or still incompletely packaged." |
1131 ) | sh $prog_path msg -r -t warn | sed -e 's;^;echo ";' -e 's;$;";' |
1132 ) | sh $prog_path msg -r -t warn | sed -e 's;^;echo ";' -e 's;$;";' |
1132 echo "set -x" |
1133 echo "set -x" |
1133 ;; |
1134 ;; |
1134 JUNK ) |
1135 JUNK ) |
1135 echo "set +x" |
1136 echo "set +x" |
1136 ( echo "This OpenPKG package is of class JUNK." |
1137 ( echo "This OpenPKG package is of class JUNK." |
1137 echo "It is still in DEVELOPMENT state," |
1138 echo "This means it is still in DEVELOPMENT state." |
1138 echo "therefore it is NOT ready to be used." |
1139 echo "Hence it is still NOT ready even for general evaluation." |
1139 echo "Do not use it at all, except in development environments!" |
1140 echo "Do not use it at all, except in development environments!" |
1140 echo "This software is either unstable or incompletely packaged." |
1141 echo "It is definitely unstable and incompletely packaged." |
1141 ) | sh $prog_path msg -r -t warn | sed -e 's;^;echo ";' -e 's;$;";' |
1142 ) | sh $prog_path msg -r -t warn | sed -e 's;^;echo ";' -e 's;$;";' |
1142 echo "set -x" |
1143 echo "set -x" |
1143 ;; |
1144 ;; |
1144 esac |
1145 esac |
1145 ;; |
1146 ;; |