Re: command line tool for this task?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I use pine here and alpine for the office, do those count?



On Mon, 16 Oct 2023, Linux for blind general discussion wrote:

Tim here.  Yep, assuming you use mail(1) to read your mail and have
it configured to send mail for you, you should be able create a
template and send mail by creating a shell-script like

$ cat send_thanks.sh
#!/bin/sh
EMAIL="$1"
SUBJECT="$2"
NAME="$3"
GIFT="$4"
mail -s "$SUBJECT" "$EMAIL" <<EOF
Dear, $NAME,
Thank you for the $GIFT you gave us.
Sincerely,
Karen
EOF


With this, you can invoke it with

 $ ./send_thanks.sh donor@xxxxxxxxxxx "We love the bucket of cash" "John & Mary Donorston" "big bucket of cash"

and it will send an email to "donor@xxxxxxxxxxx" with a subject of
"We love the bucket of cash", and the body of the email will read

 Dear, John & Mary Donorston,
 Thank you for the big bucket of cash you gave us.
 Sincerely,
 Karen

Here's hoping it helps,

-tim




On 2023-10-16 15:15, Linux for blind general discussion wrote:
Is this program a part of the standard Linux shell therefore likely to be a
part of  Shellworld using Ubuntu?
Kare



On Mon, 16 Oct 2023, Linux for blind general discussion wrote:

Have you considered using a here document in a shell script, with
variables that can be supplied for those parts of the text that change?

https://www.baeldung.com/linux/heredoc-herestring

On 16/10/23 14:45, Linux for blind general discussion wrote:
Hi folks,
Let me begin by stating that my access to Linux is a shell service,
specifically shellworld.net

what I am seeking is a tool likely to be included that lets me create a
file I will then use as a gift acknowledgment letter sent via email.
What I mean is this.
I have the name and email of a contributor.?? I create the body, but wish
to change slight details, their name, the amount their email etc.
Is there a tool in command line Linux that will provide this sort of
solution?
thanks,
Karen


_______________________________________________
Blinux-list mailing list
Blinux-list@xxxxxxxxxx
https://listman.redhat.com/mailman/listinfo/blinux-list


_______________________________________________
Blinux-list mailing list
Blinux-list@xxxxxxxxxx
https://listman.redhat.com/mailman/listinfo/blinux-list


_______________________________________________
Blinux-list mailing list
Blinux-list@xxxxxxxxxx
https://listman.redhat.com/mailman/listinfo/blinux-list

_______________________________________________
Blinux-list mailing list
Blinux-list@xxxxxxxxxx
https://listman.redhat.com/mailman/listinfo/blinux-list



_______________________________________________
Blinux-list mailing list
Blinux-list@xxxxxxxxxx
https://listman.redhat.com/mailman/listinfo/blinux-list




[Index of Archives]     [Linux Speakup]     [Fedora]     [Linux Kernel]     [Yosemite News]     [Big List of Linux Books]