# $Id: pdinrs_list,v 1.1.1.1 2005/01/10 18:47:02 pdi Exp $ #Copyright 1998-2022 Stonie R. Cooper, Licensed under the auspices of GPLv3, # See top-level copyright disclaimer (COPYRIGHT) and license (LICENSE) #! /bin/bash MAIL="/bin/mail" MAILSUB="-s" STRINGS="/usr/bin/strings" if [ ${#} -ne 3 ] then echo "usage:pdinrs_list " exit fi if [ ! -e "${1}" ] then echo "${1} (temp file) does not exist - cannot send data to list." exit fi if [ ! -e "${2}" ] then echo "${2} (list source) does not exist - cannot send data to list." exit fi for next in `cat ${2}` do # ${STRINGS} ${1} | ${MAIL} ${MAILSUB} "${3}" ${next} ${MAIL} ${MAILSUB} "${3}" ${next} < ${1} done