From 7ad81be28b930d54e0274f8a292c7d9410236a1d Mon Sep 17 00:00:00 2001 From: Tim Pope Date: Tue, 8 Jan 2013 00:48:27 -0500 Subject: [PATCH] Concede 'list' Closes #5. --- README.markdown | 2 +- plugin/sensible.vim | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/README.markdown b/README.markdown index 238091c..2f6f832 100644 --- a/README.markdown +++ b/README.markdown @@ -29,7 +29,7 @@ mostly `:set` calls.) Here's a taste: * `'backspace'`: Backspace through anything in insert mode. * `'incsearch'`: Start searching before pressing enter. -* `'listchars'`: Show trailing whitespace. +* `'listchars'`: Makes `:set list` (visible whitespace) prettier. * `'scrolloff'`: Always show at least one line above/below the cursor. * `'directory'`: Dump swap files under `~/.cache/vim/swap` (only if that directory already exists). Also `'backupdir'` and `'undodir'`. Try diff --git a/plugin/sensible.vim b/plugin/sensible.vim index a394b06..35d7914 100644 --- a/plugin/sensible.vim +++ b/plugin/sensible.vim @@ -42,8 +42,7 @@ set scrolloff=1 set sidescrolloff=5 set display+=lastline -if !&list && &listchars ==# 'eol:$' - set list +if &listchars ==# 'eol:$' set listchars=tab:>\ ,trail:-,extends:>,precedes:<,nbsp:+ if &termencoding ==# 'utf-8' || &encoding ==# 'utf-8' let &listchars = "tab:\u21e5 ,trail:\u2423,extends:\u21c9,precedes:\u21c7,nbsp:\u26ad"