Code Monkey home page Code Monkey logo

Comments (6)

tpope avatar tpope commented on August 31, 2024

Try

echo split(system('env PATH='.shellescape($PATH).' '.'ruby -rubygems -e "print Gem.path.join(%(:))"'), ':\|;')

And see what it spits back.

from vim-bundler.

darthdeus avatar darthdeus commented on August 31, 2024

It returns

E484: Can't open file /var/folders/cg/zwfpx2h14sxdy7qym06td_rc0000gn/T/v9n6BfV/3
[]

running just echo(system('ruby -rubygems -e "print Gem.path.join(%(:))"'))

will fail with

E484: Can't open file /var/folders/cg/zwfpx2h14sxdy7qym06td_rc0000gn/T/vaor7Rj/4

even though running just the ruby ruby -rubygems -e "print Gem.path.join(%(:))" seems to work

/Users/darth/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1:/Users/darth/.gem/ruby/1.9.1

from vim-bundler.

darthdeus avatar darthdeus commented on August 31, 2024

Interesting that if I run

:!ruby -rubygems -e "print Gem.path.join(%(:))"

it will work and display the path, but if I run

echo(system('ruby -rubygems -e "print Gem.path.join(%(:))"'))

it fails with the same error E484: Can't open file /var/folders/cg/zwfpx2h14sxdy7qym06td_rc0000gn/T/vrXmObe/2

from vim-bundler.

darthdeus avatar darthdeus commented on August 31, 2024

I just found that this happens only inside of the fish shell. If i chsh -s /bin/zsh and try this in a new terminal, it will work just fine. But it breaks when fish is the default. Any idea why that might be?

from vim-bundler.

darthdeus avatar darthdeus commented on August 31, 2024

Fixed by doing set shell=/bin/sh, since fish is not playing nicely with VIM.

from vim-bundler.

tpope avatar tpope commented on August 31, 2024

Yep, that's the correct solution. Vim and fish do not play well together.

from vim-bundler.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.