>%JRUBY_HOME%\bin\jruby --2.0 --version jruby 1.7.4 (2.0.0) 2013-05-16 2390d3b on Java HotSpot(TM) 64-Bit Server VM 1.7.0_21-b11 [Windows 7-amd64]
Showing posts with label JRuby. Show all posts
Showing posts with label JRuby. Show all posts
Saturday, May 18, 2013
Ruby 1.9.3-p429, Ruby 2.0.0-p195, JRuby 1.7.4 had been released
In this week, Ruby 1.9.3-p429, Ruby 2.0.0-p195 and JRuby 1.7.4 had been released. Ruby 2.0.0-p195 is the first release that is stable 2.0.x release on Windows (from here), and JRuby 1.7.4 us the first release that bundles "2.0 mode".
Saturday, October 27, 2012
Migrate JRuby from 1.6.8 to 1.7.0
Labels:
JRuby
In this week, JRuby 1.7.0 final has been released. This release becomes Ruby-1.9-based product. so that we should take care of migrating from 1.6.8 (or former) to 1.7.0 (or later).
- rename directory from jruby-1.6.8 to jruby-1.7.0
- rename from jruby-1.6.8/lib/ruby/gems/1.8 to jruby-1.7.0/lib/ruby/gems/shared
Friday, September 21, 2012
UUID in Ruby
There are 3 ways to deal UUID in Ruby.
(1) Use SecureRandom class
Check my article.(2) Install uuid gem
Check Github page of uuid gem.(3) [for JRuby] Using java.util.UUID
irb(main):001:0> require 'java' irb(main):002:0> import java.util.UUID irb(main):003:0> UUID.randomUUID.to_s => "e42ccfce-d6a0-4cb5-a0c0-9fae6ca05b84" irb(main):003:0> UUID.randomUUID.to_s => "80a31bb3-3fce-4e6f-9c8a-5a819de45960"
Friday, August 10, 2012
(Reprise) JRuby for Windows users or for Non-western languages
Labels:
JRuby
A few days ago, JRuby 1.7.0 preview 2 has been released. But, there are still some bugs - especially, ones related with Ruby 1.9 encodings. So that I re-post the blog article : phosphorescence: JRuby for Windows users or for Non-western languages.
So I hope, if you are in non-western language(Japanese, Chinese, Korean, Arabic, Hebrew and so on), I would like you to download JRuby 1.7.0 preview2, then try and test some Ruby snippets about String, IO, or its related classes, with your own language and its encoding.
Windows users
As mentioned in this article by Thomas Enebo, Windows platform becomes the first-class platform as same as Unix, Linux and Mac OS(These are de-facto platforms in OSS-develop) since JRuby 1.7.0. Ruby-lang in the JRuby goes green almost. But some gem libraries are not yet. So this article calls for gem library developers to treat Windows platform.Non-western languages
Since version 1.9, CRuby deals String class with including its own encoding. And since JRuby 1.7.0, as mentioned in this article by Charles Nutter, JRuby also deals it in the same way. It's useful way if you are reading, speaking or writing in non-western language (for me, these are in Japanese). In the current release - JRuby 1.7.0 preview2 -, It's working good for ASCII and UTF-8 characters and encodings. But It has still a bit of bugs with non-western languages and its encodings.So I hope, if you are in non-western language(Japanese, Chinese, Korean, Arabic, Hebrew and so on), I would like you to download JRuby 1.7.0 preview2, then try and test some Ruby snippets about String, IO, or its related classes, with your own language and its encoding.
Monday, May 21, 2012
JRuby 1.7.0 preview 1
Labels:
JRuby
We can try and report bugs of JRuby 1.7.0 preview 1.
A few days ago, JRuby 1.7.0 preview 1 has been tagged on github. Before you try it, you must build JRuby 1.7.0 preview 1 from source with Ant.
A few days ago, JRuby 1.7.0 preview 1 has been tagged on github. Before you try it, you must build JRuby 1.7.0 preview 1 from source with Ant.
> unzip jruby-jruby-1.7.0.preview1-0-g00c8c98.zip > cd jruby-jruby-00c8c98/ > antLet's chekc the version.
> ./bin/jruby --version jruby 1.7.0.preview1 (ruby-1.9.3-p203) (2012-05-20 fffffff) (Java HotSpot(TM) 64-Bit Server VM 1.7.0_04) [darwin-x86_64-java]As you see, since JRuby 1.7.0, default version of Ruby becomes 1.9.3 (without --1.9 option).
Saturday, February 4, 2012
JRuby 1.7 becomes 1.9 mode as default mode
Labels:
JRuby
In this issue ticket - http://jira.codehaus.org/browse/JRUBY-6387 - JRuby team surveys that JRuby 1.7 becomes 1.9 mode as default mode or not. And then, decided!!
Saturday, January 7, 2012
Enable G1GC
Since Java7 update 2, Java7 becomes stable, steadily. So that now is the time to try G1GC.
If you want to use G1GC commonly, set these VM args to environment variable JAVA_OPTS.
> java -XX:+UnlockExperimentalVMOptions -XX:+UseG1GC Another args...If you want to use G1GC commonly, set these VM args to environment variable JAVA_OPTS.
JAVA_OPTS="-XX:+UnlockExperimentalVMOptions -XX:+UseG1GC"
> java $JAVA_OPTS Another args...Another advantage to set JAVA_OPTS is that other Java programs often reads and uses this environment variable, e.g. tomcat, JRuby and so forth.
Friday, July 8, 2011
Java7 launch event in Tokyo
In yesterday, Java7 launch event was held at Aoyama, Tokyo. the program is like below:
I had two thoughts from this event.
- Opening
- Summary of Java7 & Java8
- HotRockit / New licenses for Java
- NetBeans 7.0 / Project Coin
- InvokeDynamic
- Fork/Join Framework -> Lambda
- More new I/O
- Lightning talks
- Both G1GC and InvokeDynamic are great technologies. It's good news for LLs (like JRuby) on JVM.
- But, new Java7 features for Java language are imperfect because there are lack of lambda. Those features will become perfect since Java8.
Monday, March 21, 2011
JRuby 1.6.0 has been released
Labels:
JRuby
About 1 week ago, JRuby 1.6.0 was finally released.
I repeat to say again, this release is especially useful both for windows users and for non-western language speakers. (phosphorescence: JRuby for Windows users or for Non-western languages: "Non-western language")
>%JRUBY_HOME%\bin\jruby --1.9 -S jirb
irb(main):001:0> JRUBY_VERSION
=> "1.6.0"
irb(main):002:0> RUBY_VERSION
=> "1.9.2"
irb(main):003:0> say_hello = ->(message) { "Hello #{message}" }
=> #<Proc:0x1cfd3b2@(irb):1 (lambda)>
irb(main):004:0> say_hello.("world")
=> "Hello world"I repeat to say again, this release is especially useful both for windows users and for non-western language speakers. (phosphorescence: JRuby for Windows users or for Non-western languages: "Non-western language")
Thursday, January 13, 2011
JRuby for Windows users or for Non-western languages
Three days ago, JRuby 1.6.0 RC1 has been released. IMHO, this release means "JRuby for the rest of the OSS-develop world". Where is the rest of the OSS-develop world? It's in two areas.
- Windows users
- Non-western languages
Monday, December 20, 2010
Abbrev for Multibyte characters
Each Ruby implementations have distinct behavior of abbrev library (in Japanese). There is a sample program:
"あした" means "tomorrow", and "あなた" means "you". So let's run this script on Ruby 1.9(Linux), JRuby(Linux) and IronRuby(Windows).
# -*- coding: UTF-8 -*-
require 'abbrev'
puts RUBY_VERSION
result = Abbrev.abbrev(%w{あした あなた})
puts result, result.count
"あした" means "tomorrow", and "あなた" means "you". So let's run this script on Ruby 1.9(Linux), JRuby(Linux) and IronRuby(Windows).
Wednesday, November 10, 2010
Do you know Ruby 1.9 encoding rule?
Ruby 1.9 treats the encoding within each String instance. And there are rules which encoding are defined from script or from external file. The rules are there (in Japanese).
I think, CRuby is the one and only Ruby implementation treating this rules correctly. When I had used irb, I had found its bug in JRuby and in IronRuby, and have reported this for each projects. In JRuby, this bug will be fixed for v1.6 release.
I think, CRuby is the one and only Ruby implementation treating this rules correctly. When I had used irb, I had found its bug in JRuby and in IronRuby, and have reported this for each projects. In JRuby, this bug will be fixed for v1.6 release.
Saturday, October 2, 2010
Testing ActiceRecord-JDBC with DB2 on Mac OS X
(continued from phosphorescence: Install DB2 on Mac OS X)
I helped to testing ActiveRecord-JDBC with DB2 on my Macmini. But there are two big traps. In this article, I write about the second trap : Testing ActiceRecord-JDBC with DB2 on Mac OS X.
I helped to testing ActiveRecord-JDBC with DB2 on my Macmini. But there are two big traps. In this article, I write about the second trap : Testing ActiceRecord-JDBC with DB2 on Mac OS X.
Clone sources and tests from repository
$ git clone http://github.com/nicksieger/activerecord-jdbc-adapter.git
Saturday, August 28, 2010
Friday, August 6, 2010
JRubyKaigi2010 is held with RubyKaigi2010 at same place
Labels:
JRuby,
rubykaigi2010
JRubyKaigi2010 is held with RubyKaigi2010 at same place(Tsukuba) and same time(2010/08/28). Its official site is below:
Fortunately, The sessions I want to join in RubyKaigi2010 and in JRubyKaigi2010 are not overlapping.
Fortunately, The sessions I want to join in RubyKaigi2010 and in JRubyKaigi2010 are not overlapping.
Thursday, July 8, 2010
MacPorts upgraded, Newest Ruby and JRuby are available
Repositry tree of MacPorts has been upgraded, and now, Ruby 1.9.1 p429 and JRuby 1.5.0 are both available.
$ sudo port selfupdate $ sudo port outdated ... jruby 1.4.0_0 < 1.5.0_0 ... ruby19 1.9.1-p378_0 < 1.9.1-p429_0 ... $ sudo port upgrade outdated $ sudo port -f activate jruby @1.5.0_0 $ jruby -v jruby 1.5.0 (ruby 1.8.7 patchlevel 249) (2010-07-05 6586) (Java HotSpot(TM) 64-Bit Server VM 1.6.0_20) [x86_64-java] $ ruby1.9 -v ruby 1.9.1p429 (2010-07-02 revision 28523) [i386-darwin10]I learned the sudo port -f activate jruby @1.5.0_0 instrucation. If I upgrade library on my MacPorts upto major version, sometimes needs sudo port -f activate library @version .
Subscribe to:
Posts (Atom)
