I would like for this script:
#!/bin/sh
cat source.txt | sed "/replace_text_holder/ {
r file.txt
d
}" | cat
do be written like this:
cat source.txt | sed "/replace_text_holder/ { r file.txt d }" | cat
but that doesn’t work. Anyone know why, and/or how I fix it?
I’m currently being harassed by this error:
unbalanced "{"
I’ve tried inserting “\n” to make it believe there’s a new line, but that doesn’t work.
Clearly I have no idea what I’m doing…
Try this: