sh
sh copied to clipboard
interp: here-doc backslash is not preserved
When a backslash is present inside here-doc it is not preserved in the output(input). See the difference with bash below:
gosh
$ cat << EOF
> test \" test
> EOF
test " test
bash
bash-3.2$ cat << EOF
> test \" test
> EOF
test \" test
Relates to:
- https://github.com/go-task/task/issues/1538
Thanks, this looks like a bug in the parser. I didn't know that heredocs treat backslashes unlike any other part of the language.