set listchars=tab:>-,trail:_

I tried to unset the above command this way:

unset listchars=tab:>-,trail:_

But only get:

E492: Not an editor command: unset listchars=tab:>-,trail:_

What's the right way to do this?

link|improve this question

25% accept rate
feedback

1 Answer

This will reset the listchars option to the default:

set listchars&

See the options documentation for more info.

link|improve this answer
will unset listchars= work? – gbri Jul 18 '11 at 16:20
There's no unset command. For toggleable options, you can do set nooption (example: set paste and set nopaste), but listchars is not toggleable. If you actually want to set listchars to have no value, do: set listchars= – Chris Acheson Jul 18 '11 at 16:35
so set listchars& is the same as set listchars=? – gbri Jul 19 '11 at 11:04
set listchars& sets it to the default setting that it started with, which is eol:$ – Chris Acheson Jul 19 '11 at 15:27
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.