From cd59e5d07b3a69a75f7c0d02efd66b6f04bb13a1 Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Sat, 25 Feb 2017 23:52:56 +0900 Subject: [PATCH] [neovim] Set 'dir' to the current direcotry Close https://github.com/junegunn/fzf.vim/issues/308 --- plugin/fzf.vim | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/plugin/fzf.vim b/plugin/fzf.vim index d4e4d26..932efde 100644 --- a/plugin/fzf.vim +++ b/plugin/fzf.vim @@ -290,6 +290,10 @@ try throw v:exception endtry + if has('nvim') && !has_key(dict, 'dir') + let dict.dir = getcwd() + endif + if !has_key(dict, 'source') && !empty($FZF_DEFAULT_COMMAND) let temps.source = tempname().(s:is_win ? '.bat' : '') call writefile((s:is_win ? ['@echo off'] : []) + split($FZF_DEFAULT_COMMAND, "\n"), temps.source)