########################################################################
# #
# This software is part of the ast package #
# Copyright (c) 1994-2011 AT&T Intellectual Property #
# and is licensed under the #
# Eclipse Public License, Version 1.0 #
# by AT&T Intellectual Property #
# #
# A copy of the License is available at #
# (with md5 checksum b35adb5213ca9657e911e9befb180842) #
# #
# Information and Software Systems Research #
# AT&T Research #
# Florham Park NJ #
# #
# Glenn Fowler <gsf@research.att.com> #
# #
########################################################################
command=filter
suf=
USAGE=$'
[-?
@(#)$Id: filter (AT&T Labs Research) 2001-05-31 $
]
[+DESCRIPTION?\bfilter\b runs \acommand\a in a mode that takes input from
the \afile\a operands, or from the standard input if no \afile\a
operands are specified, and writes the results to the standard output.
It can be used to run commands like \bsplit\b(1), that normally modify
\afile\a operands in-place, in pipelines. The \afile\a operands are
command [ option ... ] [ file ... ]
[+SEE ALSO?\bstrip\b(1)]
'
;;
*) ARGV0=""
USAGE="command [ option ... ] [ file ... ]"
;;
esac
{
OPTIND=0
exit 2
}
*) usage ;;
esac
done
case $# in
0) usage ;;
esac
cmd=$1
while :
do shift
case $# in
0) break ;;
esac
case $1 in
*) break ;;
esac
done
trap 'rm -f $tmp$suf' 0 1 2 3 15
case $# in
;;
*) for file
*) suf= ;;
esac
done
;;
esac