vi: Strip trailing Whitespace

This obviously was too easy for me. To strip trailing whitespace when editing a file with

vi

, just use

:%s/ *$//

{openx:6}

The space before the asterisk is important ;)

Incoming search terms:

This entry was posted in Misc, Software and tagged , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>