This regexp will match the entire contents of the three lines we just appended to the pattern space 这个规则表达式将与刚刚附加到模式空间的三行的全部内容匹配。
Sed s pattern space got ugly - we need to remove the extra newlines and perform some additional formatting Sed的模式空间变得很难看- -需要除去额外的新行,并执行某些附加的格式化。
Note the new - n option , which tells sed to not print the pattern space unless explicitly commanded to do so 请注意新的- n选项,该选项告诉sed除非明确要求打印模式空间,否则不这样做。
All of the commands in the curly braces will execute in order as soon as sed reads such a line into its pattern space 当sed将这样一行读入其模式空间时,将按顺序执行花括号中的所有命令。
For the last " oni " line , the same steps are repeated , except that the contents of the pattern space aren t deleted due to the 对于最后的" oni "行,除了不删除模式空间的内容(由于d之前的$