- or download this
echo -e 'g/\<remotely\>/.,/\<p_args\>/j\nwq' | ed -sl filename
- or download this
$ cat a
"Yes, and to be grown up,
...
"That indeed he is."
$
- or download this
for t in 's/$/ /' j; do echo -e 'g/\<remotely\>/.,/\<p_args\>/'"$t"'\n
+wq' | ed -sl filename
- or download this
g='g/\<remotely\>/.,/\<p_args\>/'; echo -e "${g}s/\$/ /\n${g}j\nwq" |
+ed -sl filename
- or download this
ex -c $'g/\<remotely\>/.,/\<p_args\>/j\nwq' filename