“p” command prints the buffer (remember to use -n option with “p”) “d” command is just opposite, its for deletion. ‘d’ will delete the pattern space buffer and immediately starts the next cycle. Syntax: # sed 'ADDRESS'd filename # sed /PATTERN/d file
转自:http://blog.csdn.net/lanmanck/article/details/8638391 上传源码时最好把空格行去掉,以前介绍了使用notepad++,现在发现,习惯用source insight的人士也可以很easy的去掉了: Options->Perferences->Files-> Remove extra white space when saving.保存时自动去除每行尾部的空格和tab. 以下是另一个兄弟的心得: http://blog.csdn.ne