jruby

What's the best practice for using bundler, git, and jRuby gems with maven?

橙三吉。 提交于 2019-12-07 06:45:45
问题 I'm working with jRuby and Rails for a while, but I don't have the feeling that I've found the holy grail for this: I'm doing a lot of gems which are wrappers for actual java libs and I ask myself what the best option is for packaging those gems. Is it a good idea to package them as "native gems", letting the jars being packaged when the gem is installed? Is there a way to install the jars in the .m2 dir, letting bundler AND maven to what they can do best at the same time? Best, Tobias 回答1:

Getting started programming in dynamic languages in Android ((J)Ruby, Clojure…)

混江龙づ霸主 提交于 2019-12-07 05:18:19
问题 I've been looking around, and I can't seem to find any definitive answer or headway that seems "up to date". I've seen some interesting projects like Mirah (formerly Duby), and am looking into it a bit. I've seen JRuby unsuccessfully used to compile ruby into .dex. I've also been looking, independently, into Clojure and have realized that they might all be linked to the same thing. Does anyone have any tips on how to get started and make headway? I ask not only what frameworks could help, but

many errors installing mysql on jruby

早过忘川 提交于 2019-12-07 03:32:11
问题 I'm trying to get mysql gem installed for use on rails, using jruby, can't figure this out...any help is appreciated! $ sudo gem install mysql2 Building native extensions. This could take a while... ERROR: Error installing mysql2: ERROR: Failed to build gem native extension. /Users/masedesign/Work/repos/code/conf/vms/ruby/jruby/bin/jruby extconf.rb WARNING: JRuby does not support native extensions or the `mkmf' library very well. Check http://kenai.com/projects/jruby/pages/Home for

How do you create a Java applet using JRuby?

家住魔仙堡 提交于 2019-12-07 03:21:09
问题 I want to create a Java applet using JRuby. That is, I want to create a Java applet with Ruby code inside run by JRuby to do all the GUI stuff. I am looking for a simple example of how to do this to get started. 回答1: Check out these links... JRubyApplet from our codebase: https://github.com/jruby/jruby/blob/master/src/org/jruby/JRubyApplet.java Rake tasks for building a signed applet: https://github.com/jruby/jruby/blob/master/rakelib/applet.rake Source for jruby.org/tryjruby page: https:/

Are there still benefits to running JRuby vs. the latest MRI with Puma?

廉价感情. 提交于 2019-12-07 00:28:57
问题 I'm considering updating our ruby interpreter to JRuby, it's been quite a headache because we've had to remove any 2.x specific syntax from our app and resort to ruby 1.9.3 compatibility. Which isn't the end of the world. When it came time to run the app, I found out that we cannot use Puma in clustered mode. The question is, given all the fixes and changes to MRI in the past few years, are the benefits of having "real threads" still valid? update To make this more objective, the question is,

Require Nokogiri? No such file to load

吃可爱长大的小学妹 提交于 2019-12-07 00:28:27
问题 I'm trying to get started with using Nokogiri. I ran the command gem install nokogiri as an administrator in Windows 7 (64-Bit). The console said "successfully installed" and "1 gem installed". When I type in gem list --local OR gem q --local I see Nokogiri on the list of "Local Gems". However, when I try to use it via the require statement (in NetBeans), I get an error that there is "no such file to load". What am I doing wrong? I'm not a Ruby professional. This is also the first gem I've

Why does devise put /devise/ in front of every link_to anchor?

旧城冷巷雨未停 提交于 2019-12-07 00:22:32
I just generated all the views for devise, and I'm starting to customize the login screen. It works great except for all the links that are generated on the sign in page start with "/devise". Why is it doing that? Seems like odd default behaviour How do I stop it from adding /devise to every link_to()? My routes file: devise_for :users get "/webpages/:page" => "webpages#show", :as => :show_webpage root :to => "webpages#index" My 'rake routes' new_user_session GET /users/sign_in(.:format) {:action=>"new", :controller=>"devise/sessions"} user_session POST /users/sign_in(.:format) {:action=>

Cannot install SQLITE3 with JRuby

血红的双手。 提交于 2019-12-07 00:09:13
问题 I am brand new to Ruby and using Windows 7. It is a different environment to what I am normally used to so I am having problems getting a simple project going. After reading several tutorials, it appears that JRuby is the simplest way to go on windows which I have done. I am now trying to create a web application from scratch but I am confused about this shell style method of working. I have downloaded sqliste3.def, sqlite3.dll and sqlite3 which I have put in the: C:jruby-1.6.4>bin directory.

Using JRuby/Jython for Ruby/Python interoperability?

房东的猫 提交于 2019-12-06 20:59:54
问题 Quite-probably a silly question, as I don't know much about Java/Jython/JRuby/bytecode, but.. I stumbled across _why's unholy again today.. It allows you to output Python bytecode from Ruby code.. Basically allowing them to produce the same bytecode.. Jython outputs Java bytecode, as does JRuby.. Since these both compile to the same bytecode, does this mean you could potentially use any Python library from Ruby, and Ruby libraries from Python? 回答1: No, that won't work. At least not the way

Btrieve/Pervasive db and Ruby

喜夏-厌秋 提交于 2019-12-06 15:55:33
问题 Is there any solution to work with Btrieve/Pervasive db from Ruby level? Any gem? Maybe somebody have some experience with such a thing? Or maybe use some Java libs through Jruby? I've never used Jruby 回答1: Never worked with that, but if there's a JDBC adapter for it, then it's a good idea to use JRuby. Using JRuby is dead simple, visit JRuby.org. 回答2: @kell I used jruby and JDBC Pervasive driver. Simple example: require "java" module JavaSql include_package "java.sql" end pervasive_driver =