# Ruby

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

[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:** 917

---

## [Simple ruby program problem](https://www.ruby-forum.com/t/simple-ruby-program-problem/158409)

<div class="topic-metadata">

**Author:** [@siguva](https://www.ruby-forum.com/u/siguva)\
**Replies:** 4\
**Last updated:** [January 23, 2009, 9:01pm UTC](https://www.ruby-forum.com/t/simple-ruby-program-problem/158409 "2009-01-23T21:01:23Z")

</div>

So I have been reading Chris P.'s book, “Learn to Program”. I am working through the examples and the “a Few Things to Try” sections at the end of each chapter. I having a problem with one of them. Here is the chapt…

---

## [Failure in library/ftools/makedirs\_spec.rb](https://www.ruby-forum.com/t/failure-in-library-ftools-makedirs-spec-rb/158479)

<div class="topic-metadata">

**Author:** [@Shri\_B](https://www.ruby-forum.com/u/Shri_B)\
**Replies:** 1\
**Last updated:** [January 23, 2009, 8:47pm UTC](https://www.ruby-forum.com/t/failure-in-library-ftools-makedirs-spec-rb/158479 "2009-01-23T20:47:37Z")

</div>

This test fails the second time I run it. I have to then manually delete the makedirs\_test folder that is created. The test tries to do system(“rmdir makedirs\_test/second\_dir”), but that fails since “/” is used. How c…

---

## [How to use two submit tag with form\_remote\_tag](https://www.ruby-forum.com/t/how-to-use-two-submit-tag-with-form-remote-tag/158470)

<div class="topic-metadata">

**Author:** [@sauravsuman012](https://www.ruby-forum.com/u/sauravsuman012)\
**Replies:** 1\
**Last updated:** [January 23, 2009, 8:22pm UTC](https://www.ruby-forum.com/t/how-to-use-two-submit-tag-with-form-remote-tag/158470 "2009-01-23T20:22:51Z")

</div>

Hi all , can we use two submit tag with form\_remote\_tag . If yes then what is the solution. Please let me help.

---

## [String doesnt auto dup on modification](https://www.ruby-forum.com/t/string-doesnt-auto-dup-on-modification/158299)

<div class="topic-metadata">

**Author:** [@sentinel](https://www.ruby-forum.com/u/sentinel)\
**Replies:** 33\
**Last updated:** [January 23, 2009, 7:29pm UTC](https://www.ruby-forum.com/t/string-doesnt-auto-dup-on-modification/158299 "2009-01-23T19:29:09Z")

</div>

I’m writing my first largeish app. One issue that gets me frequently is this: I define a string in one class. Some other class references it, and modifies it. I (somehow) expected that when another referer modifies th…

---

## [Building IronRuby](https://www.ruby-forum.com/t/building-ironruby/158418)

<div class="topic-metadata">

**Author:** [@vtphysguy](https://www.ruby-forum.com/u/vtphysguy)\
**Replies:** 3\
**Last updated:** [January 23, 2009, 6:55pm UTC](https://www.ruby-forum.com/t/building-ironruby/158418 "2009-01-23T18:55:02Z")

</div>

I’ve just gotten the latest ironruby bits from github and cannot build. Using Merlin\\Main\\Languagues\\Ruby\\IronRuby.sln: Can’t open the Microsoft.Scripting project because it imports from “Merlin\\Main\\Support\\SpecShar…

---

## [Running a program without ruby](https://www.ruby-forum.com/t/running-a-program-without-ruby/158441)

<div class="topic-metadata">

**Author:** [@siggesg](https://www.ruby-forum.com/u/siggesg)\
**Replies:** 4\
**Last updated:** [January 23, 2009, 6:44pm UTC](https://www.ruby-forum.com/t/running-a-program-without-ruby/158441 "2009-01-23T18:44:03Z")

</div>

I am a noob in programing, so don’t be mad if it’s a bad question! I wonder if i could run a program i’ve made in ruby, without CMD or ruby??

---

## [JRuby 1.1.7 will be 1.2](https://www.ruby-forum.com/t/jruby-1-1-7-will-be-1-2/158403)

<div class="topic-metadata">

**Author:** [@headius](https://www.ruby-forum.com/u/headius)\
**Replies:** 3\
**Last updated:** [January 23, 2009, 6:42pm UTC](https://www.ruby-forum.com/t/jruby-1-1-7-will-be-1-2/158403 "2009-01-23T18:42:42Z")

</div>

We’ve discussed this a bit on IRC and in real life and it’s been suggested by a number of committers and users, so we’re just going to do it. JRuby 1.1.7 will be relabeled as JRuby 1.2, to reflect how much work has g…

---

## [Questions about JRuby memcached client](https://www.ruby-forum.com/t/questions-about-jruby-memcached-client/158452)

<div class="topic-metadata">

**Author:** [@princenamor](https://www.ruby-forum.com/u/princenamor)\
**Replies:** 1\
**Last updated:** [January 23, 2009, 6:40pm UTC](https://www.ruby-forum.com/t/questions-about-jruby-memcached-client/158452 "2009-01-23T18:40:21Z")

</div>

Hi, So in light of recent discussions about bugs in the JRuby memcached client uncovered during load on the Glassfish app server ( http://tinyurl.com/apv6sk) I had a couple questions: I assume that these bugs wo…

---

## [Zlib Error in ubuntu while installing new gems](https://www.ruby-forum.com/t/zlib-error-in-ubuntu-while-installing-new-gems/158194)

<div class="topic-metadata">

**Author:** [@arun](https://www.ruby-forum.com/u/arun)\
**Replies:** 3\
**Last updated:** [January 23, 2009, 5:26pm UTC](https://www.ruby-forum.com/t/zlib-error-in-ubuntu-while-installing-new-gems/158194 "2009-01-23T17:26:03Z")

</div>

Hi, After installing the rubygems 1.3.1, I face the following issues while installing new gems. Error: arun@mysystem:~/Desktop$ sudo gem install ip2country-0.0.2.gem ERROR: While executing gem … (Zlib::GzipFile::Er…

---

## [Show error in pop up window](https://www.ruby-forum.com/t/show-error-in-pop-up-window/158440)

<div class="topic-metadata">

**Author:** [@mailtorajuit](https://www.ruby-forum.com/u/mailtorajuit)\
**Replies:** 1\
**Last updated:** [January 23, 2009, 3:34pm UTC](https://www.ruby-forum.com/t/show-error-in-pop-up-window/158440 "2009-01-23T15:34:28Z")

</div>

Hi all, In my project ,there is login page.After entering login details checks for login,if success goes to other page. if no userfound it displays error message by using flas\[:notice\]. i want to show the messaage in …

---

## [64-bit Compatibility](https://www.ruby-forum.com/t/64-bit-compatibility/158381)

<div class="topic-metadata">

**Author:** [@jbaty](https://www.ruby-forum.com/u/jbaty)\
**Replies:** 7\
**Last updated:** [January 23, 2009, 9:36am UTC](https://www.ruby-forum.com/t/64-bit-compatibility/158381 "2009-01-23T09:36:55Z")

</div>

Are there any known issues running JRuby on 64-bit machines? Currently looking to develop commercial applications, and customers will deploy these on their current web servers, which will vary by company. Some will …

---

## [Parsing java?](https://www.ruby-forum.com/t/parsing-java/158405)

<div class="topic-metadata">

**Author:** [@aguynamedryan](https://www.ruby-forum.com/u/aguynamedryan)\
**Replies:** 2\
**Last updated:** [January 23, 2009, 9:36am UTC](https://www.ruby-forum.com/t/parsing-java/158405 "2009-01-23T09:36:20Z")

</div>

I’ve now done flayjs and flayc in 70 and 61 lines of code respectively… anyone know of a java parser in ruby? That’d really fill out the set. I’d prefer if it weren’t antlr based so it is a ruby first class citizen (a…

---

## [Monopoly Walker (#188)](https://www.ruby-forum.com/t/monopoly-walker-188/157926)

<div class="topic-metadata">

**Author:** [@mansfiem](https://www.ruby-forum.com/u/mansfiem)\
**Replies:** 4\
**Last updated:** [January 23, 2009, 9:20am UTC](https://www.ruby-forum.com/t/monopoly-walker-188/157926 "2009-01-23T09:20:32Z")

</div>

Okay, this will be the last quiz I host for Ruby Q… I hope to find a new quizmaster in the coming week. -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- The three rules of Ruby Q. 2: Please do …

---

## [Http://ironruby.net get's a facelift](https://www.ruby-forum.com/t/http-ironruby-net-gets-a-facelift/157969)

<div class="topic-metadata">

**Author:** [@jsoho](https://www.ruby-forum.com/u/jsoho)\
**Replies:** 2\
**Last updated:** [January 23, 2009, 7:18am UTC](https://www.ruby-forum.com/t/http-ironruby-net-gets-a-facelift/157969 "2009-01-23T07:18:44Z")

</div>

All, http://ironruby.net should look completely different, and that’s a good thing. I spent today moving stuff around, deleting, consolidating, etc. The site is more focused on getting and using IronRuby, but don’t fe…

---

## [Strings - trying to trim values](https://www.ruby-forum.com/t/strings-trying-to-trim-values/158391)

<div class="topic-metadata">

**Author:** [@mmcolli00](https://www.ruby-forum.com/u/mmcolli00)\
**Replies:** 2\
**Last updated:** [January 23, 2009, 4:01am UTC](https://www.ruby-forum.com/t/strings-trying-to-trim-values/158391 "2009-01-23T04:01:29Z")

</div>

What is the correct way to trim off the the first 37 characters of a string? I want to trim off the value from position 0 -\> pos 37 or take off all characters from right side and stopping at a specific character #. m…

---

## [Can't read more than one message from a socket](https://www.ruby-forum.com/t/cant-read-more-than-one-message-from-a-socket/158314)

<div class="topic-metadata">

**Author:** [@dacbo](https://www.ruby-forum.com/u/dacbo)\
**Replies:** 5\
**Last updated:** [January 23, 2009, 1:57am UTC](https://www.ruby-forum.com/t/cant-read-more-than-one-message-from-a-socket/158314 "2009-01-23T01:57:26Z")

</div>

I am connecting to a server and then waiting to receive messages over the socket. For each message received I wish to then execute some code. I have tried recv, gets, and readpartial all with no luck. I tried somethin…

---

## [Zlib::Inflate error when installing gems](https://www.ruby-forum.com/t/zlib-inflate-error-when-installing-gems/158395)

<div class="topic-metadata">

**Author:** [@barby](https://www.ruby-forum.com/u/barby)\
**Replies:** 3\
**Last updated:** [January 22, 2009, 11:44pm UTC](https://www.ruby-forum.com/t/zlib-inflate-error-when-installing-gems/158395 "2009-01-22T23:44:45Z")

</div>

I think you are aware of the error… but I’d like to mention on the list that you can get around it by first installing the gem in MRI that seems to make it go away. Â» igem install bacon ERROR: While executing gem …

---

## [Design question: class methods verses initialize](https://www.ruby-forum.com/t/design-question-class-methods-verses-initialize/158372)

<div class="topic-metadata">

**Author:** [@leveille](https://www.ruby-forum.com/u/leveille)\
**Replies:** 2\
**Last updated:** [January 22, 2009, 11:01pm UTC](https://www.ruby-forum.com/t/design-question-class-methods-verses-initialize/158372 "2009-01-22T23:01:16Z")

</div>

I have a design question for a beginner: what is better for my case? I want to access functionality from a library I created. I’ve tried class methods like this: class Calc def Calc.velocity\_head(v) v\*\*2/(2.0\*G) e…

---

## [Containers](https://www.ruby-forum.com/t/containers/158358)

<div class="topic-metadata">

**Author:** [@raju](https://www.ruby-forum.com/u/raju)\
**Replies:** 2\
**Last updated:** [January 22, 2009, 10:36pm UTC](https://www.ruby-forum.com/t/containers/158358 "2009-01-22T22:36:02Z")

</div>

Hai, I have a problem with ruby containers.what is the differnce between containers and classes.Is there any syntax for containers.can you please reply me.

---

## [Passwords](https://www.ruby-forum.com/t/passwords/158291)

<div class="topic-metadata">

**Author:** [@amin1426](https://www.ruby-forum.com/u/amin1426)\
**Replies:** 7\
**Last updated:** [January 22, 2009, 8:40pm UTC](https://www.ruby-forum.com/t/passwords/158291 "2009-01-22T20:40:39Z")

</div>

Hi, I’m new to Ruby ( one day), but not to programming (over 30 years) and I would like some help. I would like to be able to read a password without echoing the characters typed. I’ve looked at getc but this echos t…

---

## [Calling class methods from C](https://www.ruby-forum.com/t/calling-class-methods-from-c/158389)

<div class="topic-metadata">

**Author:** [@rambor](https://www.ruby-forum.com/u/rambor)\
**Replies:** 3\
**Last updated:** [January 22, 2009, 8:36pm UTC](https://www.ruby-forum.com/t/calling-class-methods-from-c/158389 "2009-01-22T20:36:08Z")

</div>

Hello, I’m trying to call a class method from C. I’ve tried all combinations of rb\_intern I could think of to make it work, but I’ve gotten nothing. Example class class CallTest def go (do something here) end end …

---

## [TypeError maps to System.InvalidOperationException?](https://www.ruby-forum.com/t/typeerror-maps-to-system-invalidoperationexception/158321)

<div class="topic-metadata">

**Author:** [@Shri\_B](https://www.ruby-forum.com/u/Shri_B)\
**Replies:** 4\
**Last updated:** [January 22, 2009, 8:20pm UTC](https://www.ruby-forum.com/t/typeerror-maps-to-system-invalidoperationexception/158321 "2009-01-22T20:20:01Z")

</div>

We map Ruby’s TypeError to System.InvalidOperationException. This surprised me. I would have expected TypeError to map to System.InvalidCastException. Wouldn’t that be preferable? In general, it would be good to docum…

---

## [Ruby 1.9.1 Release Candidate 2 is released](https://www.ruby-forum.com/t/ruby-1-9-1-release-candidate-2-is-released/158220)

<div class="topic-metadata">

**Author:** [@Yugui\_SYuki\_S.S](https://www.ruby-forum.com/u/Yugui_SYuki_S.S)\
**Replies:** 1\
**Last updated:** [January 22, 2009, 8:17pm UTC](https://www.ruby-forum.com/t/ruby-1-9-1-release-candidate-2-is-released/158220 "2009-01-22T20:17:50Z")

</div>

\-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi, folks Ruby 1.9.1 Release Candidate 2 has been released. This is a release candidate of Ruby 1.9.1, which will be the first stable version of Ruby 1.9 series. You can…

---

## [Howto call static java method from Jruby?](https://www.ruby-forum.com/t/howto-call-static-java-method-from-jruby/158004)

<div class="topic-metadata">

**Author:** [@Diamantini\_Maurice](https://www.ruby-forum.com/u/Diamantini_Maurice)\
**Replies:** 2\
**Last updated:** [January 22, 2009, 7:29pm UTC](https://www.ruby-forum.com/t/howto-call-static-java-method-from-jruby/158004 "2009-01-22T19:29:29Z")

</div>

Bonjour à tous, Choco is a bsd licenced java constraint programming framework. I use it from some (litle) project and for (french) teaching. The course is finished, but I consider to switch from java to JRuby next ye…

---

## [Showing a file](https://www.ruby-forum.com/t/showing-a-file/158303)

<div class="topic-metadata">

**Author:** [@siggesg](https://www.ruby-forum.com/u/siggesg)\
**Replies:** 6\
**Last updated:** [January 22, 2009, 5:37pm UTC](https://www.ruby-forum.com/t/showing-a-file/158303 "2009-01-22T17:37:10Z")

</div>

I am a noob in programing, and have just learned some of the basics. And i wonder if i could show a file (like a picture) when running the program??.

---

## [\[ANN\] yamltest 0.5.0 Released](https://www.ruby-forum.com/t/ann-yamltest-0-5-0-released/158370)

<div class="topic-metadata">

**Author:** [@gazoduc](https://www.ruby-forum.com/u/gazoduc)\
**Replies:** 0\
**Last updated:** [January 22, 2009, 4:28pm UTC](https://www.ruby-forum.com/t/ann-yamltest-0-5-0-released/158370 "2009-01-22T16:28:29Z")

</div>

This is the first release for yamltest, freshly extracted from zena, a rails CMS (http://zenadmin.org). yamltest yamltest is a simple helper to write parts of your unit tests using yaml. For a real world example of s…

---

## [Non latin characters and File(x).size](https://www.ruby-forum.com/t/non-latin-characters-and-file-x-size/158369)

<div class="topic-metadata">

**Author:** [@vitaliys](https://www.ruby-forum.com/u/vitaliys)\
**Replies:** 0\
**Last updated:** [January 22, 2009, 4:19pm UTC](https://www.ruby-forum.com/t/non-latin-characters-and-file-x-size/158369 "2009-01-22T16:19:21Z")

</div>

Hello. I use Ruby(mswin32/cygwin)/JRuby on Windows platform. I can’t get File(x).size if file name (x) contains non latin characters such as some french (“Ã§”) or russian letters. Code: #!/bin/ruby $KCODE = ‘u’ re…

---

## [Ruby/MySQL code generator](https://www.ruby-forum.com/t/ruby-mysql-code-generator/158285)

<div class="topic-metadata">

**Author:** [@nctodc](https://www.ruby-forum.com/u/nctodc)\
**Replies:** 2\
**Last updated:** [January 22, 2009, 2:03pm UTC](https://www.ruby-forum.com/t/ruby-mysql-code-generator/158285 "2009-01-22T14:03:42Z")

</div>

CodeFutures has just released a new version of FireStorm/DAO which can now generate Ruby source code implementing the Data Access Object (DAO) design pattern. The generated code relies on the mysql-ruby module to acce…

---

## [Shoes Video Support on Linux](https://www.ruby-forum.com/t/shoes-video-support-on-linux/158000)

<div class="topic-metadata">

**Author:** [@tcsnide](https://www.ruby-forum.com/u/tcsnide)\
**Replies:** 3\
**Last updated:** [January 22, 2009, 1:58pm UTC](https://www.ruby-forum.com/t/shoes-video-support-on-linux/158000 "2009-01-22T13:58:18Z")

</div>

When downloading Shoes for Linux I did not see a binary package with video support. Is there a reason for this? Will such a package be forth coming? And if not is there a way to detect in a program if video support if…

---

## [Adding Pathname#abspath()](https://www.ruby-forum.com/t/adding-pathname-abspath/148515)

<div class="topic-metadata">

**Author:** [@Akinori\_MUSHA](https://www.ruby-forum.com/u/Akinori_MUSHA)\
**Replies:** 17\
**Last updated:** [January 22, 2009, 1:35pm UTC](https://www.ruby-forum.com/t/adding-pathname-abspath/148515 "2009-01-22T13:35:58Z")

</div>

ã€€SUSv3ã®realpath(3)ã®é …ã«ã¯ã€å­˜åœ¨ã—ãªã„ã‚³ãƒ³ãƒãƒ¼ãƒãƒ³ãƒˆãŒã‚ã£ãŸã‚‰ errno=ENOENT ã‚’è¿”ã™ã¹ã—(shall fail)ã¨ã‚ã‚‹ã®ã§ã™ãŒã€\*BSDã§ã¯æœ€å¾Œã® ã‚³ãƒ³ãƒãƒ¼ãƒãƒ³ãƒˆã«é™ã‚Šå­˜åœ¨ã—ãªã…

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

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