Fix ruby scripting