Hi,
The manual says,
-r Backslash does not act as an escape character. The
backslash is considered to be part of the line. In particular, a
back-
slash-newline pair may not be used as a line continuation.
The following example shows that "\" at the line end means line
continuation. Is this wrong? Or I misunderstand the document?
~/linux/test/gnu/bash/man/builtin/read/-d$ ./main.sh
abc\'asdf"Hello
foo"bar"''
~/linux/test/gnu/bash/man/builtin/read/-d$ cat ./main.sh
#!/usr/bin/env bash
my_var=Hello
read -r -d '' VAR <<EOF
abc\'asdf"\
$my_var
foo"bar"''
EOF
echo "$VAR"
--
Regards,
Peng