diff options
author | Junegunn Choi <junegunn.c@gmail.com> | 2016-07-26 02:35:40 +0900 |
---|---|---|
committer | Junegunn Choi <junegunn.c@gmail.com> | 2016-07-26 02:37:12 +0900 |
commit | f787f7e65108938fda981abb71f4fdfb08fd9f31 (patch) | |
tree | 85131066923318cb13ff4b40c61bbaf46a805307 /README.md | |
parent | a7c9c08371d27b550f3896ab554f6490871a7a0a (diff) |
[vim] Add fzf#wrap helper function
Close #627
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 17 |
1 files changed, 14 insertions, 3 deletions
@@ -320,10 +320,10 @@ customization. [fzf-config]: https://github.com/junegunn/fzf/wiki/Configuring-FZF-command-(vim) -#### `fzf#run([options])` +#### `fzf#run` -For more advanced uses, you can use `fzf#run()` function with the following -options. +For more advanced uses, you can use `fzf#run([options])` function with the +following options. | Option name | Type | Description | | -------------------------- | ------------- | ---------------------------------------------------------------- | @@ -342,6 +342,17 @@ options. Examples can be found on [the wiki page](https://github.com/junegunn/fzf/wiki/Examples-(vim)). +#### `fzf#wrap` + +`fzf#wrap(name string, [opts dict, [fullscreen boolean]])` is a helper +function that decorates the options dictionary so that it understands +`g:fzf_layout`, `g:fzf_action`, and `g:fzf_history_dir` like `:FZF`. + +```vim +command! -bang MyStuff + \ call fzf#run(fzf#wrap('my-stuff', {'dir': '~/my-stuff'}, <bang>0)) +``` + Tips ---- |