vim-hugefile


Ⅰ. 插件描述

Speed up loading of large files.

Ⅱ. 基本信息

创建日期:  2013-10-27
使用用户:  51
Github星:  54
插件作者:  Marco Hinz

Ⅲ. 安装方法

使用Vundle管理器安装

在你的.vimrc下添加:
Plugin 'mhinz/vim-hugefile'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall

对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。

使用NeoBundle管理器安装

在你的.vimrc下添加:
NeoBundle 'mhinz/vim-hugefile'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall

使用VimPlug管理器安装

在你的.vimrc下添加:
Plug 'mhinz/vim-hugefile'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall

使用Pathogen管理器安装

在终端中运行以下命令:
cd ~/.vim/bundle
git clone https://github.com/mhinz/vim-hugefile

Ⅳ. 文档说明

[![No Maintenance
Intended](http://unmaintained.tech/badge.svg)](http://unmaintained.tech/)

vim-hugefile

Vim always loads entire files. Therefore loading huge files (logfiles?) is
pretty slow. And having the usual options set makes loading even slower.

This plugin reduces the impact of the latter heavily by disabling these options
for all huge files:

  • FileType autocmds
  • syntax highlighting
  • folding
  • swapfile
  • MatchParen

This happens automatically for all files that are bigger or equal to 2 MiB. You
can change this value by setting g:hugefile_trigger_size (in MiB) in your
vimrc.

Before the options for handling huge files are set, your old settings get saved.
:HugefileToggle toggles the current state.

Alternatives?

Yes, there's also
LargeFile, but my eyes
felt the strong urge to die in a raging fire when they saw the code. Moreover..
vimball, enough said.

It just doesn't look like modern VimL.

Real alternatives?

Honestly, don't use Vim for big files. Or use filters to read only certain
parts:

$ vim <(tail hugelogfile)

添加新评论