2014-09-23 69 views
0

Eclim的粉丝们,我已被降级到Windows,cygwin是我真正的操作系统的唯一内存。毫无疑问,Windows 7比其前任更好,但我是一个非常顽固的* nix粉丝。无论如何,我卡住了。如果有人有任何想法,我会很高兴听到他们!在cygwin的vim中使用eclim

$ uname -a 
CYGWIN_NT-6.1 AAXA22A492 1.7.32(0.274/5/3) 2014-08-13 23:06 x86_64 Cygwin 
$ vim --version | head -3 
VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Aug 25 2014 19:00:15) 
Included patches: 1-417 
Compiled by <[email protected]> 
$ cat .vimrc 
" required for eclime (and general sanity): 
set nocompatible 
filetype plugin indent on 

syntax on 
set tabstop=3 shiftwidth=3 expandtab 
set ic 

$ tree -L 2 .vim 
.vim 
|-- eclim 
| |-- autoload 
| |-- bin 
| |-- compiler 
| |-- dict 
| |-- doc 
| |-- ftplugin 
| |-- indent 
| |-- plugin 
| `-- syntax 
`-- plugin 
    `-- eclim.vim 

11 directories, 1 file 
$ vim 
Error detected while processing function <SNR>8_Init..eclim#LoadVimSettings..ecl 
im#UserHome..eclim#cygwin#WindowsHome..<SNR>10_Cygpath..eclim#util#System..eclim 
#util#EchoTrace: 
line 7: 
E121: Undefined variable: g:EclimHighlightTrace 
E116: Invalid arguments for function <SNR>11_EchoLevel 
Error detected while processing function <SNR>8_Init..eclim#LoadVimSettings..ecl 
im#UserHome..eclim#cygwin#WindowsHome..<SNR>10_Cygpath: 
line 6: 
E171: Missing :endif 
Error detected while processing function <SNR>8_Init..eclim#LoadVimSettings..ecl 
im#UserHome..eclim#cygwin#WindowsHome: 
line 2: 
E171: Missing :endif 
Error detected while processing function <SNR>8_Init..eclim#LoadVimSettings..ecl 
im#UserHome: 
line 3: 
E171: Missing :endif 
Press ENTER or type command to continue 
+0

纳米是可以接受的还是必须是VIM? – wlraider70 2014-09-23 19:56:39

回答

0

Eric在this thread上解决了此问题 - 解决方案复制如下。

谢谢Eric!

--- a/org.eclim.core/vim/eclim/autoload/eclim.vim 
+++ b/org.eclim.core/vim/eclim/autoload/eclim.vim 
@@ -352,6 +350,11 @@ function! eclim#ShutdownEclim() " {{{ 
endfunction " }}} 

function! eclim#LoadVimSettings() " {{{ 
+ if !exists('g:EclimLogLevel') 
+ let g:EclimLogLevel = 'info' 
+ let g:EclimHighlightTrace = 'Normal' 
+ endif 
+ 
    let settings_file = eclim#UserHome() . '/.eclim/.eclim_settings' 
    if filereadable(settings_file) 
    let lines = readfile(settings_file) 

--- a/org.eclim.core/vim/eclim/autoload/eclim/client/nailgun.vim 
+++ b/org.eclim.core/vim/eclim/autoload/eclim/client/nailgun.vim 
@@ -153,7 +153,7 @@ function! eclim#client#nailgun#GetEclimCommand(home) " {{{ 
    if has('win32unix') 
    " in cygwin, we must use 'cmd /c' to prevent issues with eclim script + 
    " some arg containing spaces causing a failure to invoke the script. 
- return 'cmd /c "' . eclim#cygwin#WindowsPath(command) . '"' 
+ return [0, 'cmd /c "' . eclim#cygwin#WindowsPath(command) . '"'] 
    endif 
    return [0, '"' . command . '"'] 
endfunction " }}}