From 1b76276ea831ee5cb657e0261ff5fe472626118f Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Fri, 20 Jul 2018 20:31:13 +1200 Subject: Overhaul for new version Refactor completely, mostly for clarity of code rather than speed. Also accept a range and deal with vertical whitespace trimming intelligently based on its value. --- README.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'README.md') diff --git a/README.md b/README.md index 4ea75b4..abddc14 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ strip\_trailing\_whitespace.vim =============================== -This plugin provides a mapping target with the author's approach to stripping +This plugin provides a user command with the author's approach to stripping trailing whitespace from an entire buffer, including removing empty or whitespace-only lines at the end of the buffer, without making command noise and without moving the cursor from its current position. @@ -9,15 +9,14 @@ and without moving the cursor from its current position. This is a very commonly written and implemented plugin, but I wrote my own because I could not find a plugin that did this in exactly the way I wanted: -- Provide a `` mapping +- Accept an optional range - Strip trailing lines as well as trailing spaces -- Accurately report what was changed +- Report what was changed, accurately - Work with even very old Vim (>=6.0) - Work with a single `undo` - Don't move the cursor - Don't change the search pattern - Don't define an `autocmd` -- Don't define a user command - Don't force a key mapping - Don't define a global function -- cgit v1.2.3