Vi Cheatsheet

My Cheats

Converting text files from one format to another:

keywords: fileformat

:e ++ff=<source-format>
:setlocal ff=<target-format>
:w

vi supports these file formats:

  • mac (EOL = CR)
  • dos (EOL = CR+LF)
  • unix (EOL = LF)

(src: http://vim.wikia.com/wiki/File_format)

Other Good Cheatsheets

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License