以下命令是什么意思:
sed -e '/SUBCKT\ REDBK128S4_LC/,/ENDS/ d' $1
Run Code Online (Sandbox Code Playgroud)
代表什么,?
它指定要RANGE在其上应用d命令的位置。
可以使用以下模式指定范围:
sed -e '/START/,/END/ command' # apply command on lines between START and END pattern
Run Code Online (Sandbox Code Playgroud)
或像这样的行号:
sed -e '1,35 command' # apply command on lines 1 to 35
Run Code Online (Sandbox Code Playgroud)
或混合使用,例如:
sed '1200,$ {/abc/ command}' # apply command on lines 1200 to end of file that contain "abc"
Run Code Online (Sandbox Code Playgroud)