Feb 12, 2013 pow · jruby · hack · sockets · support

Let jRuby and Pow!™ be happy together

Turns out that Pow! won’t support jRuby anytime soon but the trick described in josh/nack#32 actually works, so rollup your shirt’s sleeves!

Go open node_modules/nack/lib/nack/server.rb inside ~/Library/Application Support/Pow/Current and replace sock.close_read on line 132 with:

# WAS: sock.close_read
begin
  sock.close_read
rescue IOError
  raise unless RUBY_ENGINE == 'jruby'
end

Happy hacking!