SEX! or, how do I mail to a lot of unix users?

Randal Schwartz merlyn at iwarp.intel.com
Fri Jun 1 09:01:38 AEST 1990


In article <JASON.90May31163242 at aelle.cs.odu.edu>, jason at cs (Jason C Austin) writes:
| #!/bin/sh
| 
| users=`cat user-list`
| 
| for user in $users
|  do
|   echo "Mailing $user"
|   mail $user < message
|  done


Too many processes.  If you want progress reporting, say:

while read user
do
	echo "Mailing $user"
	mail $user <message
done <user-list

If not, try:

mail `cat user-list` <message

Simple.

Just another mail admin,
-- 
/=Randal L. Schwartz, Stonehenge Consulting Services (503)777-0095 ==========\
| on contract to Intel's iWarp project, Beaverton, Oregon, USA, Sol III      |
| merlyn at iwarp.intel.com ...!any-MX-mailer-like-uunet!iwarp.intel.com!merlyn |
\=Cute Quote: "Welcome to Portland, Oregon, home of the California Raisins!"=/



More information about the Comp.unix.questions mailing list