maassen@kreon.informatik.rwth-aachen.de (Andreas Maassen) (06/27/91)
I always used the following print command with xmh Xmh*PrintCommand: lpr -Plaser -h >/dev/null 2>/dev/null Everything worked well until I wanted to use an additional filter: Xmh*PrintCommand: mp -l | lpr -Plaser -h -c >/dev/null 2>/dev/null With this print command, nothing happens, although the command as such is correct, since it works if I type it into a shell. Any suggestions what might be wrong? Andreas Maassen (maassen@informatik.rwth-aachen.de)
jerry@ora.com (Jerry Peek) (06/27/91)
In article <maassen.678015703@kreon> maassen@kreon.informatik.rwth-aachen.de (Andreas Maassen) writes: > Xmh*PrintCommand: mp -l | lpr -Plaser -h -c >/dev/null 2>/dev/null > > With this print command, nothing happens, although the command > as such is correct, since it works if I type it into a shell. The problem is that xmh tacks the filenames to print onto the *end* of the command line, after the pipe. The command xmh runs to print messages 1 and 2 in your inbox will be like: mp -l | lpr -Plaser -h -c >/dev/null 2>/dev/null inbox/1 inbox/2 Write a little shell script that puts the filenames (inbox/1 inbox/2) in the right place and use that shell script as the Xmh*PrintCommand. The "MH & xmh" Nutshell Handbook has an "xmhprint" shell script in section 12.8. You can get a copy of it by anonymous ftp or uucp from uunet.uu.net in the file nutshell/MHxmh/MHxmh.tar.Z. --Jerry Peek, jerry@ora.com or uunet!ora!jerry