Ⅰ. 插件描述
open the next or previous fileⅡ. 基本信息
|
Ⅲ. 安装方法
使用Vundle管理器安装
在你的.vimrc下添加:Plugin 'tyru/nextfile'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall
对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。
使用NeoBundle管理器安装
在你的.vimrc下添加:NeoBundle 'tyru/nextfile'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall
使用VimPlug管理器安装
在你的.vimrc下添加:Plug 'tyru/nextfile'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall
使用Pathogen管理器安装
在终端中运行以下命令:cd ~/.vim/bundle
git clone https://github.com/tyru/nextfile.vim
Ⅳ. 文档说明
Usage:
COMMANDS:
:NFLoadGlob
load globbed files.
this command just load files to buffers, does not edit them.
options do NOT influence globbed file's list.
:NFLoadGlob * " to load all files in current directory.
:NFLoadGlob .* " to load all dotfiles in current directory.
MAPPING:
default:
<Leader>n - open the next file
<Leader>p - open the previous file
GLOBAL VARIABLES:
g:nf_map_next (default: '<Leader>n')
open the next file.
g:nf_map_previous (default: '<Leader>p')
open the previous file.
g:nf_include_dotfiles (default: 0)
if true, open the next dotfile.
if false, skip the next dotfile.
g:nf_open_command (default: 'edit')
open the (next|previous) file with this command.
g:nf_loop_files (default: 0)
if true, loop when reached the end.
g:nf_ignore_dir (default: 1)
if true, skip directory.
g:nf_ignore_ext (default: [])
ignore files of these extensions.
e.g.: "o", "obj", "exe"
g:nf_disable_if_empty_name (default: 0)
do not run mapping if current file name is empty.
behave like old version if this is true.
g:nf_commands (default: see below)
command's names.
if you do not want to define some commands,
please leave '' in command's value.
e.g.: let g:nf_commands = {'NFLoadGlob': ''}
default value:
let g:nf_commands = {
'NFLoadGlob' : 'NFLoadGlob',
}
g:nf_sort_funcref (default: '<SID>sort_compare')
function string or Funcref passed to sort().
default function's definition:
func! s:sort_compare(i, j)
" alphabetically
return a:i > a:j
endfunc