csscomb / vim-csscomb

CSScomb plugin for Vim. Tool for sorting CSS properties in specific order.
csscomb.com
134 stars 18 forks source link

Delete and append instead of setline, to prevent bug when result line… #12

Open iovar opened 9 years ago

iovar commented 9 years ago

When the lines after combing are fewer than before combing, the extra lines remain in the buffer and mess up the file. e.g.

.format { width: 100px; height: 200px;

border: 2px solid blue; }

will result to this:

.format { width: 100px; height: 200px; border: 2px solid blue; } }

By deleting the lines and then appending, this doesn't happen and the result is correct.

netcookies commented 8 years ago

u may want to use "delete_" instead of "delete", prevent to cut the tempfile in clipboard