Problem with Vim's Ruby plugin

后端 未结 6 1061
一整个雨季
一整个雨季 2021-02-13 18:34

I have just installed Vim and when ever I go to open in ruby file I get these errors:

Error detected while processing C:\\Program files (x86)\\Vim\\vimfiles\\ftp         


        
6条回答
  •  走了就别回头了
    2021-02-13 19:10

    If you run RVM and want its default ruby, use:

    let g:ruby_path = "/Users/allen/.rvm/rubies/default/bin"
    

    If you set your ruby interpreter in your project .rvmrc file, you can create an environment variable in your .rvmrc:

    rvm 1.9.2@projectname --create
    export RUBY_BIN=`which ruby | sed 's/ruby$//'`
    

    You can use environment variables in your .vimrc:

    let g:ruby_path=$RUBY_BIN
    

    (Note you should also set a default $RUBY_BIN in your .bashrc or .zshrc so this works outside of .rvmrc projects.)

    If your ~/.rvm/rubies/default/bin path does not yet exist, you need to set your rvm system default of ruby. At your command prompt or terminal application, enter:

    rvm use 1.9.2 --default
    

    using whatever ruby version you need.

提交回复
热议问题