blob: 2202f47bc727ae1b3c9702e7f8d26a61ac7836a4 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
" Don't join lines with two spaces at the end of sentences; I don't two-space,
" despite the noble Steve Losh's exhortations
set nojoinspaces
" Strip trailing whitespace with \x
if has('eval')
function! StripTrailingWhitespace()
let l:search = @/
%substitute/\s\+$//e
let @/ = l:search
nohlsearch
endfunction
nnoremap <silent> <leader>x :<C-U>call StripTrailingWhitespace()<CR>
endif
|