# Ruby

**URL:** https://www.ruby-forum.com/c/ruby/7.md?page=1062

[Latest](https://www.ruby-forum.com/latest.md) · [Categories](https://www.ruby-forum.com/categories.md) · [Tags](https://www.ruby-forum.com/tags.md)

**Page:** 1063

---

## [Use memcache with JRuby](https://www.ruby-forum.com/t/use-memcache-with-jruby/144458)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 0\
**Last updated:** [July 29, 2008, 8:32pm UTC](https://www.ruby-forum.com/t/use-memcache-with-jruby/144458 "2008-07-29T20:32:26Z")

</div>

I have just started learning JRuby and should admit that it’s really a nice stuff, thanks for all your effort guys. My problem is as following: We have a live service(IMPS like service) running on RoR. But the perfo…

---

## [Rake mspec:... broken in r127](https://www.ruby-forum.com/t/rake-mspec-broken-in-r127/144251)

<div class="topic-metadata">

**Author:** [@editkid](https://www.ruby-forum.com/u/editkid)\
**Replies:** 10\
**Last updated:** [July 29, 2008, 8:09pm UTC](https://www.ruby-forum.com/t/rake-mspec-broken-in-r127/144251 "2008-07-29T20:09:01Z")

</div>

After shifting up to 127 I can’t get run the rubyspecs any more. I fixed up the .irconfig.rb and default.mspec files correctly (by the way I had to explicitly specify the MRI binary file in .irconfig.rb since it didn…

---

## [Bj-0.0.2](https://www.ruby-forum.com/t/bj-0-0-2/122967)

<div class="topic-metadata">

**Author:** [@ara.t.howard](https://www.ruby-forum.com/u/ara.t.howard)\
**Replies:** 15\
**Last updated:** [July 29, 2008, 7:15pm UTC](https://www.ruby-forum.com/t/bj-0-0-2/122967 "2008-07-29T19:15:43Z")

</div>

(note: i just pushed 0.0.2 up and the gem mirrors typically take ~ 30 minutes to sync - be sure you get 0.0.2!) NAME bj SYNOPSIS bj (migration\_code|generate\_migration|migrate|setup|run|submit| list|set|config|pid) …

---

## [jRuby and net/ssh](https://www.ruby-forum.com/t/jruby-and-net-ssh/144413)

<div class="topic-metadata">

**Author:** [@Yvon\_T](https://www.ruby-forum.com/u/Yvon_T)\
**Replies:** 2\
**Last updated:** [July 29, 2008, 7:11pm UTC](https://www.ruby-forum.com/t/jruby-and-net-ssh/144413 "2008-07-29T19:11:02Z")

</div>

Hey all, i’m using net/ssh with CRuby and wanted an UI then, i’ve migrated to jRuby + Profligacy. except the UI the code is about the same and i get an error when authentifying : Exception in thread “AWT-EventQueue…

---

## [Converting Ruby class to Java class](https://www.ruby-forum.com/t/converting-ruby-class-to-java-class/144420)

<div class="topic-metadata">

**Author:** [@alisajjad\_mushtaq](https://www.ruby-forum.com/u/alisajjad_mushtaq)\
**Replies:** 7\
**Last updated:** [July 29, 2008, 6:41pm UTC](https://www.ruby-forum.com/t/converting-ruby-class-to-java-class/144420 "2008-07-29T18:41:40Z")

</div>

Hi all, I’m wondering is there a way to convert a ruby class to java class. Think of the following code Class X; end x = X.new x.class # Gives me the ruby Class for this object Now I have a java method which accept…

---

## [Camping not saving @state](https://www.ruby-forum.com/t/camping-not-saving-state/144274)

<div class="topic-metadata">

**Author:** [@no137b](https://www.ruby-forum.com/u/no137b)\
**Replies:** 6\
**Last updated:** [July 29, 2008, 6:20pm UTC](https://www.ruby-forum.com/t/camping-not-saving-state/144274 "2008-07-29T18:20:34Z")

</div>

I have a sqlite3 database with the sessions table and schema set up correctly. Sessions are created fine and put in the table, the cookie is set with the correct hash and the hash is found again but when using @state …

---

## [About class in module](https://www.ruby-forum.com/t/about-class-in-module/144402)

<div class="topic-metadata">

**Author:** [@Kyung\_won\_C](https://www.ruby-forum.com/u/Kyung_won_C)\
**Replies:** 3\
**Last updated:** [July 29, 2008, 5:51pm UTC](https://www.ruby-forum.com/t/about-class-in-module/144402 "2008-07-29T17:51:51Z")

</div>

– test1.rb – class C def a end end class C def a puts “override” end end puts C.new.a # =\> override – test2.rb – class C def a end end module M class C def a puts “why not override?” end end end in…

---

## [Inexplicable failure](https://www.ruby-forum.com/t/inexplicable-failure/144431)

<div class="topic-metadata">

**Author:** [@bburcham](https://www.ruby-forum.com/u/bburcham)\
**Replies:** 2\
**Last updated:** [July 29, 2008, 5:49pm UTC](https://www.ruby-forum.com/t/inexplicable-failure/144431 "2008-07-29T17:49:33Z")

</div>

I’m getting an inexplicable error when I try to run this script. Here’s the script, and the error message I get. require ‘watir’ require ‘spec’ require ‘dl’ b = Watir::IE.start(‘http://www.tv.com/tv-awards/?page=27’…

---

## [Text comparision](https://www.ruby-forum.com/t/text-comparision/144425)

<div class="topic-metadata">

**Author:** [@karthicg](https://www.ruby-forum.com/u/karthicg)\
**Replies:** 1\
**Last updated:** [July 29, 2008, 4:13pm UTC](https://www.ruby-forum.com/t/text-comparision/144425 "2008-07-29T16:13:21Z")

</div>

hi, i need to check the text “Test” from a dropdown list that contains more than 100 char. i have taken the text from dropdown list and store it in a variable a.(i dont know is it correct or not) that is if i execut…

---

## [Re: JRuby-Rack 0.9 RackInitializationException on Tomcat: The system cannot find the path specified](https://www.ruby-forum.com/t/re-jruby-rack-0-9-rackinitializationexception-on-tomcat-the-system-cannot-find-the-path-specified/144421)

<div class="topic-metadata">

**Author:** [@tbaustert](https://www.ruby-forum.com/u/tbaustert)\
**Replies:** 0\
**Last updated:** [July 29, 2008, 3:11pm UTC](https://www.ruby-forum.com/t/re-jruby-rack-0-9-rackinitializationexception-on-tomcat-the-system-cannot-find-the-path-specified/144421 "2008-07-29T15:11:11Z")

</div>

Yes, I grabbed the latest version, and it appears that the fix for JRUBY-2594 corrected this problem. Thanks, Â Â Â Tom ----- Original Message ---- From: Nick S. removed\_email\_address@domain.invalid To: removed\_em…

---

## [Net-ssh and remote shell](https://www.ruby-forum.com/t/net-ssh-and-remote-shell/144244)

<div class="topic-metadata">

**Author:** [@Une\_BSSSSvS\_ue](https://www.ruby-forum.com/u/Une_BSSSSvS_ue)\
**Replies:** 8\
**Last updated:** [July 29, 2008, 2:46pm UTC](https://www.ruby-forum.com/t/net-ssh-and-remote-shell/144244 "2008-07-29T14:46:36Z")

</div>

following the page : http://drnicwilliams.com/2006/09/22/remote-shell-with-ruby/ i’ve uninstalled net-ssh and the like then, intall needle-1.3.0.gem and re-installed : net-ssh-2.0.3.gem net-scp-1.0.1.gem net-ssh-g…

---

## [Can't control regular expressions](https://www.ruby-forum.com/t/cant-control-regular-expressions/144401)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 2\
**Last updated:** [July 29, 2008, 12:59pm UTC](https://www.ruby-forum.com/t/cant-control-regular-expressions/144401 "2008-07-29T12:59:15Z")

</div>

Hello guys, I need to extract from an html file all the scripts. So I have written the following regular expression for a first test: %r|\<script(.+)script\>|m The problem I am having is that the expression takes the …

---

## [\[Ruby 1.9 - Bug #369\] Ruby 1.9.0-3$B$G(B R](https://www.ruby-forum.com/t/ruby-1-9-bug-369-ruby-1-9-0-3-b-g-b-r/144410)

<div class="topic-metadata">

**Author:** [@Akira\_M](https://www.ruby-forum.com/u/Akira_M)\
**Replies:** 0\
**Last updated:** [July 29, 2008, 12:57pm UTC](https://www.ruby-forum.com/t/ruby-1-9-bug-369-ruby-1-9-0-3-b-g-b-r/144410 "2008-07-29T12:57:30Z")

</div>

e$B%A%1%C%He(B #369 e$B$,99?7$5$l$^$7$?!#e(B (by Akira M.) e$B5/I\<;~E@$Ne(Btrunke$B$Ne(B ruby 1.9.0 (2008-07-29 revision 18256) \[i686-darwin9.4.0\] e$B$G$b:F8=$7$^$7$?!#e(B http://redmine.ruby-lang.org/issues/show/369 …

---

## [\[Ruby 1.8 - Bug #367\] (Closed) ruby\_1\_8$B$N(Brss$B$G(B3E](https://www.ruby-forum.com/t/ruby-1-8-bug-367-closed-ruby-1-8-b-n-brss-b-g-b3e/144409)

<div class="topic-metadata">

**Author:** [@Kouhei\_S](https://www.ruby-forum.com/u/Kouhei_S)\
**Replies:** 0\
**Last updated:** [July 29, 2008, 12:40pm UTC](https://www.ruby-forum.com/t/ruby-1-8-bug-367-closed-ruby-1-8-b-n-brss-b-g-b3e/144409 "2008-07-29T12:40:31Z")

</div>

e$B%A%1%C%He(B #367 e$B$,99?7$5$l$^$7$?!#e(B (by Kouhei S.) e$B%9%F!\<%?%9e(B Opene$B$+$ie(BClosede$B$KJQ99e(B r18246 http://redmine.ruby-lang.org/issues/show/367

---

## [Problem with command line arguments](https://www.ruby-forum.com/t/problem-with-command-line-arguments/144396)

<div class="topic-metadata">

**Author:** [@alisajjad\_mushtaq](https://www.ruby-forum.com/u/alisajjad_mushtaq)\
**Replies:** 1\
**Last updated:** [July 29, 2008, 12:18pm UTC](https://www.ruby-forum.com/t/problem-with-command-line-arguments/144396 "2008-07-29T12:18:49Z")

</div>

Hi all, I’m wondering could anyone tell me what is wrong with this command (using jruby 1.1.3): java -jar jruby-complete.jar --1.9 myscript.rb output : jruby: unknown option --1.9 Thanks, – Cheers, -A Ali S., …

---

## [\[Ruby 1.9 - Bug #369\] Ruby 1.9.0-3$B$G(B R](https://www.ruby-forum.com/t/ruby-1-9-bug-369-ruby-1-9-0-3-b-g-b-r/144399)

<div class="topic-metadata">

**Author:** [@Akira\_M](https://www.ruby-forum.com/u/Akira_M)\
**Replies:** 0\
**Last updated:** [July 29, 2008, 11:41am UTC](https://www.ruby-forum.com/t/ruby-1-9-bug-369-ruby-1-9-0-3-b-g-b-r/144399 "2008-07-29T11:41:51Z")

</div>

e$B%A%1%C%He(B #369 e$B$,99?7$5$l$^$7$?!#e(B (by Akira M.) e$B$9$\_$^$;$s!\*%?%$%H%k$,$R$I$$$3$H$K$J$C$F$7$^$$$^$7$?!&!&!&e(B e$B$I$J$?$+8"8B$N$“$kJ}!”%?%$%H%k$r!Ve(BRuby 1.9e$B$Ge(BRailse$B$Ne(Bactionpacke$B$N%F%9%H$N…

---

## [$home](https://www.ruby-forum.com/t/home/144309)

<div class="topic-metadata">

**Author:** [@editkid](https://www.ruby-forum.com/u/editkid)\
**Replies:** 3\
**Last updated:** [July 29, 2008, 9:58am UTC](https://www.ruby-forum.com/t/home/144309 "2008-07-29T09:58:41Z")

</div>

By the way, this is how $HOME is setup in mspec (on Windows): # Code to setup HOME directory correctly on Windows # This duplicates Ruby 1.9 semantics for defining HOME platform\_is :windows do if ENV\['HOME'\] E…

---

## [Does Railway department need private Security Agency?](https://www.ruby-forum.com/t/does-railway-department-need-private-security-agency/144388)

<div class="topic-metadata">

**Author:** [@abcotech](https://www.ruby-forum.com/u/abcotech)\
**Replies:** 0\
**Last updated:** [July 29, 2008, 9:51am UTC](https://www.ruby-forum.com/t/does-railway-department-need-private-security-agency/144388 "2008-07-29T09:51:28Z")

</div>

Recently I amd my friend were visiting one of the best raily station in USA and India, We show there is not security restication, the government security person was not working properly. According to my and my friends …

---

## [Problems with throw/catch (newbie)](https://www.ruby-forum.com/t/problems-with-throw-catch-newbie/144256)

<div class="topic-metadata">

**Author:** [@tlockney](https://www.ruby-forum.com/u/tlockney)\
**Replies:** 9\
**Last updated:** [July 29, 2008, 9:17am UTC](https://www.ruby-forum.com/t/problems-with-throw-catch-newbie/144256 "2008-07-29T09:17:03Z")

</div>

I’m trying to do something that I think would be pretty trivial. I’ve read in an external file as an array. I want to parse the array of lines, and set a line number as a variable if the line matches a certain patte…

---

## [Gsup with variable when replacing](https://www.ruby-forum.com/t/gsup-with-variable-when-replacing/144307)

<div class="topic-metadata">

**Author:** [@Romain\_LOMBARDO](https://www.ruby-forum.com/u/Romain_LOMBARDO)\
**Replies:** 4\
**Last updated:** [July 29, 2008, 8:55am UTC](https://www.ruby-forum.com/t/gsup-with-variable-when-replacing/144307 "2008-07-29T08:55:59Z")

</div>

Hi people, I’m trying to transform this kind of line : 123232321 FOOFOOFOO … 2431232 BARBARBAR to 123232321 (actually XML) 2431232 So I have coded this script File.open(“D:/digisoft/1b.txt”,“r”) do |f2| whil…

---

## [\[ANN\] Warbler 0.9.10 released, includes JRuby 1.1.3 and JRuby-Rack 0.9.1](https://www.ruby-forum.com/t/ann-warbler-0-9-10-released-includes-jruby-1-1-3-and-jruby-rack-0-9-1/144177)

<div class="topic-metadata">

**Author:** [@nicksnels](https://www.ruby-forum.com/u/nicksnels)\
**Replies:** 2\
**Last updated:** [July 29, 2008, 8:50am UTC](https://www.ruby-forum.com/t/ann-warbler-0-9-10-released-includes-jruby-1-1-3-and-jruby-rack-0-9-1/144177 "2008-07-29T08:50:08Z")

</div>

Hey all, I finally got around to fixing some of the bugs you reported, and cut a new Warbler gem with JRuby 1.1.3. Please check it out, and let me know if you see any issues. Changes: 0.9.10 Upgraded to JRuby-Rack…

---

## [Using Antwrap in Ruby](https://www.ruby-forum.com/t/using-antwrap-in-ruby/143879)

<div class="topic-metadata">

**Author:** [@srinu](https://www.ruby-forum.com/u/srinu)\
**Replies:** 2\
**Last updated:** [July 29, 2008, 8:45am UTC](https://www.ruby-forum.com/t/using-antwrap-in-ruby/143879 "2008-07-29T08:45:47Z")

</div>

Hi , I am trying to install Antwrap-0.7.0.gem and rjb-1.1.x gems in cygwin and windows also , I’m stuck so I thought I ping out to see if anyone else has done this. Last one week i have been working on issue .Any he…

---

## [Running ab command in cron](https://www.ruby-forum.com/t/running-ab-command-in-cron/144335)

<div class="topic-metadata">

**Author:** [@voodoox33](https://www.ruby-forum.com/u/voodoox33)\
**Replies:** 2\
**Last updated:** [July 29, 2008, 5:35am UTC](https://www.ruby-forum.com/t/running-ab-command-in-cron/144335 "2008-07-29T05:35:33Z")

</div>

def get\_web\_performance(instance\_url) web\_performance = -111 ab\_command = “ab -n 1000 -c 5 -d -S -k http://” + instance\_url + "/dbcon/index.php:80/ " puts ab\_command result = IO.popen(ab\_command) puts result pipe …

---

## [Win32ole equivalent for Mac OS X](https://www.ruby-forum.com/t/win32ole-equivalent-for-mac-os-x/144333)

<div class="topic-metadata">

**Author:** [@nathandelane](https://www.ruby-forum.com/u/nathandelane)\
**Replies:** 11\
**Last updated:** [July 29, 2008, 5:11am UTC](https://www.ruby-forum.com/t/win32ole-equivalent-for-mac-os-x/144333 "2008-07-29T05:11:56Z")

</div>

Is there an equivalent library for the Win32ole library on the PC? I use this library to read word .doc files, but when I try to run the script on Mac OS X, it doesn’t recognize it. Any possibilities?

---

## [WxRuby GridCellChoiceEditor Segfault](https://www.ruby-forum.com/t/wxruby-gridcellchoiceeditor-segfault/144370)

<div class="topic-metadata">

**Author:** [@Glen\_H](https://www.ruby-forum.com/u/Glen_H)\
**Replies:** 0\
**Last updated:** [July 29, 2008, 5:02am UTC](https://www.ruby-forum.com/t/wxruby-gridcellchoiceeditor-segfault/144370 "2008-07-29T05:02:35Z")

</div>

Does anyone have a specific experience with WxRuby’s GridCellChoiceEditor causing a segfault? I’m sure it’s something simple I’m doing wrong but have no idea how to fix it. Here is the code that is causing the segf…

---

## [Re. Packaging JRuby Swing app using Profligacy into a .jar](https://www.ruby-forum.com/t/re-packaging-jruby-swing-app-using-profligacy-into-a-jar/196764)

<div class="topic-metadata">

**Author:** [@chrisdwan](https://www.ruby-forum.com/u/chrisdwan)\
**Replies:** 0\
**Last updated:** [July 29, 2008, 2:39am UTC](https://www.ruby-forum.com/t/re-packaging-jruby-swing-app-using-profligacy-into-a-jar/196764 "2008-07-29T02:39:20Z")

</div>

On Jul 28, 7:01 pm, “Vladimir S.” removed\_email\_address@domain.invalid wrote: Hi Chris, Maybe this article by Matt Fletcher would be of help:http:// spin.atomicobject.com/2008/07/02/rolling-a-jruby-desktop-appli… Th…

---

## [What is %w](https://www.ruby-forum.com/t/what-is-w/144343)

<div class="topic-metadata">

**Author:** [@jsamildanach](https://www.ruby-forum.com/u/jsamildanach)\
**Replies:** 5\
**Last updated:** [July 29, 2008, 1:49am UTC](https://www.ruby-forum.com/t/what-is-w/144343 "2008-07-29T01:49:39Z")

</div>

What is the %w used for in ruby?

---

## [Rails or Tomcat - which one to be used for background task?](https://www.ruby-forum.com/t/rails-or-tomcat-which-one-to-be-used-for-background-task/196763)

<div class="topic-metadata">

**Author:** [@rmehta](https://www.ruby-forum.com/u/rmehta)\
**Replies:** 0\
**Last updated:** [July 29, 2008, 1:33am UTC](https://www.ruby-forum.com/t/rails-or-tomcat-which-one-to-be-used-for-background-task/196763 "2008-07-29T01:33:49Z")

</div>

Hi, I need advice on a decision that I have to make to decide whether I should do background task in Rails or in Tomcat. What I need to do is that a user of web app will create nnumber of text messages which need to…

---

## ["or" and "and"](https://www.ruby-forum.com/t/or-and-and/144296)

<div class="topic-metadata">

**Author:** [@es\_S](https://www.ruby-forum.com/u/es_S)\
**Replies:** 9\
**Last updated:** [July 29, 2008, 1:02am UTC](https://www.ruby-forum.com/t/or-and-and/144296 "2008-07-29T01:02:18Z")

</div>

Hi, I’m just getting to discover ruby, but I find it very nice programming language. I just still don’t understand how the “or” and “and” in ruby… I was playing with ruby and for example made a def to print Stem and …

---

## [Weird backsplash behaviour inside single quotes](https://www.ruby-forum.com/t/weird-backsplash-behaviour-inside-single-quotes/144117)

<div class="topic-metadata">

**Author:** [@Michal\_S](https://www.ruby-forum.com/u/Michal_S)\
**Replies:** 12\
**Last updated:** [July 29, 2008, 12:45am UTC](https://www.ruby-forum.com/t/weird-backsplash-behaviour-inside-single-quotes/144117 "2008-07-29T00:45:19Z")

</div>

Hello I observe that backslashed characters normally produce backaslash plus the character inside single quotes. The understandable exception are single quotes. However, in Ruby double backslash also produces a singl…

[Previous page](https://www.ruby-forum.com/c/ruby/7.md?page=1061)

[Next page](https://www.ruby-forum.com/c/ruby/7.md?page=1063)
