Guest User

Untitled

a guest
Dec 18th, 2017
357
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.54 KB | None | 0 0
  1. MAILADDR=(mail1@example.com, mail2@example.com, mail3@example.com)
  2. for i in "${MAILADDR[@]}"
  3. do
  4. echo "Mail test..." | mail -s "Mail test subject..." $i
  5. done
  6.  
  7. echo"/home/user/information-for-any-user.txt" | mail -s "Mail test subject..." $i ??
  8.  
  9. mail -s "My subject" $(cat /this/is/the/external/flat/file.txt) < /home/user/information-for-any-user.txt
  10.  
  11. echo "Mail test..." | mail -s "Mail test subject..." $(< address.file)
  12.  
  13. mapfile -t addr < address.file
  14. echo "Mail test..." | mail -s "Mail test subject..." "${addr[@]}"
Add Comment
Please, Sign In to add comment