Shougo / denite.nvim

:dragon: Dark powered asynchronous unite all interfaces for Neovim/Vim8
Other
2.06k stars 215 forks source link

Error when pressing <C-c> to quit #84

Closed Asheq closed 7 years ago

Asheq commented 7 years ago

Problem summary

When I press \<C-c> (Control + C) to quit Denite, it gives me an error instead of quiting

image

Expected

I expect Denite to quit.

Environment Information

" Your minimal init.vim
set runtimepath+=~/.vim/bundle/repos/github.com/Shougo/denite.nvim/

The reproduce ways from gVim

  1. Start gVim
  2. Start denite with any source, for example ":Denite line"
  3. Press \<C-c> to attempt to quit denite

Thank you!

Keep up the amazing work Shougo! I love all of your plugins, and I'm looking forward to Vim8 support for deoplete and the other dark-powered plugins.

laughingman-hass commented 7 years ago

I believe this issue is only exists in vim 8.0. <C-c> quits denite as expected in neovim. A workaround for now in vim 8.0 would be to map <C-c> to <Esc> while in denite, maybe something like this

augroup filetype_denite
  autocmd!
  autocmd FileType denite call s:denite_keymapping()
augroup END

function! s:denite_keymapping()
  map <buffer> <C-c>     <Esc>
endfunction
Asheq commented 7 years ago

@hass-laughingman, thanks but the work-around you mentioned doesn't seem to work for me. I can wait for one of @lambdalisue's PRs to be merged.