0

i've installed BeautifyRuby in my Sublime Text 2 (running OS X Yosemite 10.10), but is not working, I receive this message when I try to cmd + ctrl + k:

Error: invalid output. Check your ruby interpreter settings

I've changed, as suggested https://github.com/CraigWilliams/BeautifyRuby , the sublime-settings file with:

"ruby": "/Users/alessiogastaldo/.rbenv/bin/ruby"

and also using the specific version:

"ruby": "/Users/alessiogastaldo/.rbenv/versions/1.8.7-p371/bin/ruby"

but with no success.

I've read the different solutions proposed (like https://github.com/CraigWilliams/BeautifyRuby/issues/52) but nothing works.

Anyone do know how to solve this?

JasonMArcher
  • 14,195
  • 22
  • 56
  • 52
AlessioG
  • 576
  • 5
  • 13
  • 32

1 Answers1

1

I had the same problem too. I solved with this:

  1. In terminal, run the command: which ruby.
  2. Copy the result. In my case was: "/home/user/.rbenv/shims/ruby"
  3. Open your package settings. In my case: Preferences > Package Settings > BeautyfyRuby > Settings Default.
  4. Add this line in the file: "ruby": "/home/user/.rbenv/shims/ruby",

You will need to install the htmlbeautifier gem.

  1. Run the commmand in terminal: gem install htmlbeautifier

It works for me.

Diego Somar
  • 941
  • 1
  • 11
  • 28