delete those lines which have no content :
:g/^$/d
delete those lines which are only composed of "space":
:g/^\s*$/d
delete those lines which are composed of "space or tab":
:g/^[ |\t]*$/d
刪除沒有內容的空行
:g/^$/d
:g/^$/d
刪除包含有空格組成的空行
:g/^\s*$/d
:g/^\s*$/d
除以空格或tab開頭到結尾的空行
:g/^[ |\t]*$/d
:g/^[ |\t]*$/d
From http://blog.cmchen.net/2006/12/25/325/
No comments:
Post a Comment