HOWTO: make vim show ending line spaces as characters

less than 1 minute read

When you edit a file with vim, it’s useful to understand where the line ends especially if there are spaces at the end of the line. Instead checking all lines, you can highlight white spaces. How?

  1. Open Vim from Terminal
  2. Type

    :set list
  3. You see an output like the one below
  4. If you want see each space as character, type this command

    :set listchars=eol:$,tab:>-,trail:~,extends:>,precedes:<
  5. The output should look like below

Very simple and useful tip! :)

If you have any doubt, advice or something else, comment this post! :)

Source: Stackoverflow

Leave a comment