How do I reduce the loading time for very large files in Vim?
You can use the following settings to reduce the loading time for very large files in Vim:
:set lazyredraw
:set noswapfile
:set undolevels=-1
:set eventignore=all
:set nohidden
:set syntax=off
Note that the above settings will disable many Vim features including the following: Swap files support for crash recovery, undo support, syntax highlighting, filetype detection and other autocommand based features. There is also the LargeFile plugin available at https://www.vim.org/scripts/script.php?script_id=1506 which automatically sets these options, when working with large files (it is configurable, what is considered to be a large file, by default, it is 100MB).
Comments (1)
Pepsh Pepshinsky
Let’s see you to :help viminfo-file-name (option -i) :set viminfofile=NONE