xref: /titanic_51/usr/src/contrib/ast/src/cmd/INIT/silent.sh (revision b4dd7d09880f14016feece03929a224eca1cf39a)
1########################################################################
2#                                                                      #
3#               This software is part of the ast package               #
4#          Copyright (c) 1994-2011 AT&T Intellectual Property          #
5#                      and is licensed under the                       #
6#                 Eclipse Public License, Version 1.0                  #
7#                    by AT&T Intellectual Property                     #
8#                                                                      #
9#                A copy of the License is available at                 #
10#          http://www.eclipse.org/org/documents/epl-v10.html           #
11#         (with md5 checksum b35adb5213ca9657e911e9befb180842)         #
12#                                                                      #
13#              Information and Software Systems Research               #
14#                            AT&T Research                             #
15#                           Florham Park NJ                            #
16#                                                                      #
17#                 Glenn Fowler <gsf@research.att.com>                  #
18#                                                                      #
19########################################################################
20# non-ksh stub for the nmake silent prefix
21# @(#)silent (AT&T Research) 1992-08-11
22
23case $-:$BASH_VERSION in
24*x*:[01234567899]*)	: bash set -x is broken :; set +ex ;;
25esac
26
27while	:
28do	case $# in
29	0)	exit 0 ;;
30	esac
31	case $1 in
32	*=*)	case $RANDOM in
33		$RANDOM)`echo $1 | sed "s/\\([^=]*\\)=\\(.*\\)/eval \\1='\\2'; export \\1/"` ;;
34		*)	export "$1" ;;
35		esac
36		shift
37		;;
38	*)	break
39		;;
40	esac
41done
42"$@"
43