sed命令的功能:1.删除特定行cat -s /etc/php.ini |sed '/^[[:space:]]*$/d' > php.ini.new2.替换字符串sed -r "s/s*jdbc.passwords*=s*S+/jdbc.password=$2/g" -i jdbc.properties3.删除字符串前后的空白行
echo " fffxx " | sed -e 's/^[[:space:]]//' -e 's/[[:space:]]$//'