26 lines
649 B
Plaintext
26 lines
649 B
Plaintext
|
#!/bin/sh
|
||
|
#
|
||
|
# From the Cedilla man-page:
|
||
|
#
|
||
|
# Cedilla is unable to print data that comes from
|
||
|
# a pipe; this is unavoidable, as Cedilla makes two passes
|
||
|
# over its input file.
|
||
|
#
|
||
|
# This small wrapper script makes it possible to use pipe.
|
||
|
# For example:
|
||
|
#
|
||
|
# cat infile | cedilla-pipe [options] > outfile
|
||
|
# cedilla-pipe [options] < infile > outfile
|
||
|
#
|
||
|
# Mon Feb 17 21:50:39 2003 Mike FABIAN <mfabian@suse.de>
|
||
|
|
||
|
TEMPFILE=`mktemp /tmp/cedilla-pipe.XXXXXX` || exit 1
|
||
|
cleanup="rm -r $TEMPFILE"
|
||
|
trap "exec $cleanup" EXIT SIGHUP SIGINT SIGPIPE SIGTERM SIGIO
|
||
|
|
||
|
cat > $TEMPFILE
|
||
|
cedilla ${1+"$@"} $TEMPFILE
|
||
|
|
||
|
# exit calls cleanup
|
||
|
exit 0
|