sed error: unterminated 's' command
sed, unix
Solution
You need to use quoting to protect special characters, including spaces, `$`, and `*`.
sed -i 's/abc=.*$/abc=def ghi/g' hpq_sf_attach_wf_param.txt
Problem
I run below sed command ``` sed -i s/abc=.*$/abc=def ghi/g hpq_sf_attach_wf_param.txt ``` and it gave me error: ``` sed: -e expression #1, char 17: unterminated `s' command ``` I noticed it is due to space in between of `def` and `ghi`. Any idea how to fix it?