line="Include /2" rep="" sed -e "s/${line}/${rep}/g" /root/new_scripts/a.conf
sed -e "s|${line}|${rep}|g" /root/new_scripts/a.conf
References :
bash - replace a string in file using shell script - Stack Overflow
沒有留言:
張貼留言