job_id = 10
I want to replace JOB_ID_DEFAULT with 10
start writing
sed 's/JOB_ID_DEFAULT/${job_id}/' test > test.ctl
No, I later found that the outer layer can be changed to double quotation marks.
sed "s/JOB_ID_DEFAULT/${job_id}/" test > test.ctl
http://blog.csdn.net/zxx2403/article/details/7245339