1

How to make G-WAN's Ruby to use JRuby Instead of Ruby, this is what i've tried:

$ which ruby
/usr/bin/ruby
$ cd /usr/bin
$ mv ruby ruby2
$ ln -s `which jruby` ruby
$ ruby --version
jruby 1.7.4 (2.0.0) 2013-05-16 2390d3b on OpenJDK Client VM 1.7.0_40-b31 +indy [linux-i386]
$ ruby2 --version
ruby 2.0.0p247 (2013-06-27 revision 41674) [i686-linux]

but when i install Ruby, this message shows up (this doesn't show before):

test.rb: to use   .rb scripts, install Ruby

the purpose was so i could possibly use Java's import api.Gwan (include_package api.Gwan), since there are no (or i'm not yet found it on the docs) API provided to Ruby (to access the cookie, access the KV, etc)

EDIT: ah, i don't think this would be useful -_-", since not a full API implemented on GWAN's Java

package api;
public class Gwan {
  public static native long getReply(long paramLong);
  public static native void xbufCat(long paramLong, String paramString);
  public static native long cycles64();
  public static native long getNs();
  public static native long getUs();
  public static native long getMs();
  public static native void logErr(long paramLong, String paramString);
  public static native void report(long paramLong, int paramInt);
}
4

1 に答える 1