From fdc6d0b41ed472f6a1c19ee1200a5d58232d45a5 Mon Sep 17 00:00:00 2001 From: Alisue Date: Wed, 11 Aug 2021 14:37:50 +0900 Subject: [PATCH 1/2] :bug: Use proper `mode` even when denops servers are restarted --- autoload/denops/util.vim | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/autoload/denops/util.vim b/autoload/denops/util.vim index 9b55fa94..c7c28298 100644 --- a/autoload/denops/util.vim +++ b/autoload/denops/util.vim @@ -2,14 +2,15 @@ let s:sep = has('win32') ? '\' : '/' let s:root = expand(':h:h:h') function! denops#util#meta() abort + let mode = g:denops#_test ? 'test' : g:denops#debug ? 'debug' : 'release' if exists('s:meta') - return s:meta + return extend({'mode': mode}, s:meta, 'keep') endif let l:host = has('nvim') ? 'nvim' : 'vim' let l:version = s:get_host_version() let l:platform = has('win32') ? 'windows' : has('mac') ? 'mac' : 'linux' let s:meta = { - \ 'mode': g:denops#_test ? 'test' : g:denops#debug ? 'debug' : 'release', + \ 'mode': mode, \ 'host': l:host, \ 'version': l:version, \ 'platform': l:platform, From 5bd1ac033b0d0a48ee9778dac931eb12e3488dd1 Mon Sep 17 00:00:00 2001 From: Alisue Date: Wed, 11 Aug 2021 14:41:38 +0900 Subject: [PATCH 2/2] :memo: Add WARNING for using `input()` in debug mode Close #93 --- doc/denops.txt | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/doc/denops.txt b/doc/denops.txt index 28a0a1d5..cc3347f1 100644 --- a/doc/denops.txt +++ b/doc/denops.txt @@ -45,6 +45,11 @@ VARIABLE *denops-variable* Note that the debug mode would affect the performance so disable it unless you are debugging deno plugins. + WARNING In debug mode, any interactive functions (such as |input()|) + does not work properly in Vim prior to 8.2.3081 due to internal + workaround implementations. See an issue #93 for details. + https://github.com/vim-denops/denops.vim/issues/93 + Default: 0 *g:denops#server#channel#deno*