From: Christian Brabandt Date: Thu, 30 Jan 2025 09:58:07 +0000 (+0100) Subject: runtime(netrw): correct wrong version check X-Git-Tag: v9.1.1057~1 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=6d6ec2ee054b93ea7705a584607956d06dadfe35;p=thirdparty%2Fvim.git runtime(netrw): correct wrong version check The version check introduced with commit edd4ac3e8 has a logic error. Also it should only trigger when trying to use the netrw plugin and not always. fixes: #16541 Signed-off-by: Christian Brabandt --- diff --git a/runtime/pack/dist/opt/netrw/autoload/netrw.vim b/runtime/pack/dist/opt/netrw/autoload/netrw.vim index 7d7ff15df7..243ff8738f 100644 --- a/runtime/pack/dist/opt/netrw/autoload/netrw.vim +++ b/runtime/pack/dist/opt/netrw/autoload/netrw.vim @@ -21,6 +21,11 @@ endif let g:loaded_netrw = "v176" +if !has("patch-9.1.1054") && !has('nvim') + echoerr 'netrw needs Vim v9.1.1054' + finish +endif + let s:keepcpo= &cpo setl cpo&vim "DechoFuncName 1 diff --git a/runtime/plugin/netrwPlugin.vim b/runtime/plugin/netrwPlugin.vim index f3684bb27f..6d7a8660ff 100644 --- a/runtime/plugin/netrwPlugin.vim +++ b/runtime/plugin/netrwPlugin.vim @@ -1,10 +1,5 @@ " Load the netrw package. -if !has("patch-9.1.1054") || !has('nvim') - echoerr 'netrw needs vim v9.1.1054' - finish -endif - if &cp || exists("g:loaded_netrw") || exists("g:loaded_netrwPlugin") finish endif