Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!mit-eddie!uw-beaver!ubc-cs!alberta!ccu!mills From: mills@ccu.umanitoba.ca (Gary Mills) Newsgroups: comp.unix.questions Subject: Sending quotes to rsh Message-ID: <1990Jul26.202645.20915@ccu.umanitoba.ca> Date: 26 Jul 90 20:26:45 GMT Organization: University of Manitoba, Winnipeg, Canada Lines: 24 Is this the best way to quote the remote arguements to rsh? It works, but seems a bit complicated. This is SunOs 4.0.3. ---------------8<---------------------8<---------------------- #!/bin/sh # usage: mailer [-f from] address address ... # O="-f MAILER-DAEMON" S=other_host case $1 in -f) O="-f '$2'";shift 2;; esac R="$O" for A in "$@" do R="$R '$A'" done rsh $S echo "$R" ## -- -Gary Mills- -University of Manitoba- -Winnipeg-