I'm working on a bash-script that has to prepare an E-Mail for being sent to a user.
It aggregates some data, which ends up being multiple lines of stuff. For the example stored in $DATA
.
Now, after a bit of stfw I found a few things like sed -ei "s/_data_/${DATA}/g" mail.tpl
and also sed replace with variable with multiple lines. None of them work.
Now the question is, how do I get sed
to replace something with multiple lines of text?
(Alternatives to sed
are also welcome!)