:g/^$/dBreaking this down. The "g" will execute a command on lines that match a regular expression. The regular expression matches blank lines, and the command is "d" (delete).
Thursday, December 19, 2013
Removing Blank Lines
Here's a handy one-liner to remove blank lines from a file.