Delete comments with Vim :g/^\s*#/d will remove comment lines that begin with # from a file with Vim. Tweet