remind(1) provides a function shell() documented as follows:
shell(s_cmd [,i_maxlen])
Executes cmd as a system command, and returns the first 511
characters of output resulting from cmd. Any whitespace
character in the output is converted to a space. Note that if
RUN OFF has been executed, or the -r command-line option has
been used, shell() will result in an error, and cmd will not be
executed.
…
I would like whatever s_cmd writes to stdout to be interpreted
by remind itself. E. g.:
$ echo REM Sep 13 2018 MSG test >/tmp/test.rem
$ tail -2 ~/.reminders
SET tmp shell("cat /tmp/test.rem", -1)
$tmp
Where $tmp is my unsuccessful attempt at inserting the output of the
command in the line above. When executing rem(1), it does not return an
error but it does not interpolate $tmp either:
$ rem
Reminders for Thursday, 13th September, 2018 (today):
…
$tmp
I assume that $tmp is interpreted as an implicit REM … statement.
(The INCLUDE directive does not work in this context because I need
the output of the inclusion to be generated in situ.)