I have the following code
#!/bin/bash
v=""
for f in a123*
do
# echo "Processing $f file";
#mail -a $f -s " Test" Ab@gmail.com < /dev/null
v=$v" -a "$f
done
mail $v -s " Test" Ab@gmail.com < /dev/null
I have a procedure which converts table data into flat files and saves it in a directory. I need to mail those flat files according to email id which is being provided as input via procedure Right now I am hard coding the email id but I need to map the email id according to user input. The mail should be sent to the email ID provided by user.