Resolution: Won't Fix
Affects Version/s: JRuby 1.0.0RC2
Fix Version/s: None
Environment:Linux cat-in-the-hat 2.6.21-1-686 #1 SMP Sat May 26 16:14:59 UTC 2007 i686 GNU/Linux
(Debian using official packages from Debian unstable)
Number of attachments :
GROOVY-1936 (http://jira.codehaus.org/browse/GROOVY-1936) also applies to the JRuby interpreter. When using the interpreter in the shebang of one of my own scripts, Linux's recursive shebang handling is screwed up, so it tries to run my script in bash (rather than in jruby).
[bloom@cat-in-the-hat nouns]$ cat test.rb
[bloom@cat-in-the-hat nouns]$ ./test.rb
./test.rb: line 2: puts: command not found
The proper fix is to translate the jruby1.0 command to C, and to compile and install that on UNIX systems. Alternatively, speak to the linux-kernel mailing list about this, as I am uncertain whether this shebang handling behavior is a feature or a bug.