Search code examples
vim

Vim Error: E474: Invalid argument: listchars=tab:»·,trail:·


Summary:

I am receiving the following error for having the below line in my .vimrc file

Error:

E474: Invalid argument: listchars=tab:»·,trail:·

.vimrc:

set list listchars=tab:»·,trail:·

I have researched this and it appears to have something to do with UTF-8 encoding being properly set.

System Setup:

lsb_release:

Distributor ID: Ubuntu
Description:    Ubuntu 12.04 LTS
Release:        12.04
Codename:       precise

Locale:

LANG=en_US.UTF-8
LANGUAGE=
LC_CTYPE="en_US"
LC_NUMERIC="en_US"
LC_TIME="en_US"
LC_COLLATE="en_US"
LC_MONETARY="en_US"
LC_MESSAGES="en_US"
LC_PAPER="en_US"
LC_NAME="en_US"
LC_ADDRESS="en_US"
LC_TELEPHONE="en_US"
LC_MEASUREMENT="en_US"
LC_IDENTIFICATION="en_US"
LC_ALL=en_US

Solution

  • Solution:

    Place the following lines at the top of the .vimrc the error mentions:

    .vimrc:

    scriptencoding utf-8
    set encoding=utf-8