8

I have JRuby and Git for windows installed. I then installed Ruby 2.3 x64 using RubyInstaller. I then installed the x64 devkit. I installed the json gem and it ran correctly. Running rake --version gives me the error:

bash: /c/Ruby23-x64/bin/rake: C:/Users/Justin/Projects/rubyinstaller/sandbox/ruby23_mingw/bin/ruby.exe: bad interpreter: Permission denied

My name is not Justin, there are no users on my computer or network named Justin, and I don't even have any friends named Justin. What is causing this issue?

3
  • try opening cmd as administrator: right click cmd and run as administrator
    – Nirupa
    Commented Apr 28, 2016 at 21:16
  • it works in cmd. Why won't it work in mingw64?
    – griest
    Commented Apr 28, 2016 at 21:18
  • @nirupa I figured it out.
    – griest
    Commented Apr 28, 2016 at 21:34

1 Answer 1

11

Go into the bin folder of your ruby installation and edit the rake file. Change the first line from #!C:/Users/Justin/Projects/rubyinstaller/sandbox/ruby23_mingw/bin/ruby.exe to #!ruby.exe or the absolute path your ruby executable if its not in your PATH.

2
  • so you had to set the path
    – Nirupa
    Commented Apr 28, 2016 at 21:35
  • No my path was already set. The rake command was referencing a ruby exe on the dev's machine
    – griest
    Commented Apr 28, 2016 at 21:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.