# Ruby

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

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

---

## [Creating sub-classes using Struct](https://www.ruby-forum.com/t/creating-sub-classes-using-struct/94552)

<div class="topic-metadata">

**Author:** [@eliben](https://www.ruby-forum.com/u/eliben)\
**Replies:** 7\
**Last updated:** [May 7, 2006, 8:01am UTC](https://www.ruby-forum.com/t/creating-sub-classes-using-struct/94552 "2006-05-07T08:01:31Z")

</div>

Hello, There are two Ruby features I want to combine. One is sub-classes (or embedded classes): class Foo def initialize(x) puts “new Foo #{x}” end class Bar def initialize(y) puts "new Bar #{y}" end end end …

---

## [Ruby-GetText-Package-1.5.0](https://www.ruby-forum.com/t/ruby-gettext-package-1-5-0/59831)

<div class="topic-metadata">

**Author:** [@Masao\_M](https://www.ruby-forum.com/u/Masao_M)\
**Replies:** 0\
**Last updated:** [May 7, 2006, 6:54am UTC](https://www.ruby-forum.com/t/ruby-gettext-package-1-5-0/59831 "2006-05-07T06:54:50Z")

</div>

Hi, Ruby-GetText-Package-1.5.0 is now available. Changes Support Russian. Fix bugs. Refresh mo option was added. Check mo files and reload it if it’s updated. ruby -d or GetText::TextDomain.check\_mo=(true). Or dev…

---

## [Problem with block](https://www.ruby-forum.com/t/problem-with-block/59821)

<div class="topic-metadata">

**Author:** [@andy](https://www.ruby-forum.com/u/andy)\
**Replies:** 2\
**Last updated:** [May 7, 2006, 5:03am UTC](https://www.ruby-forum.com/t/problem-with-block/59821 "2006-05-07T05:03:15Z")

</div>

Why does the following method return nil? def foo info = " What |Removed |Added Status|RESOLVED |CLOSED " result = Hash.new info.each do |li…

---

## [Gem update mysql issue](https://www.ruby-forum.com/t/gem-update-mysql-issue/59794)

<div class="topic-metadata">

**Author:** [@sweatje](https://www.ruby-forum.com/u/sweatje)\
**Replies:** 2\
**Last updated:** [May 7, 2006, 1:33am UTC](https://www.ruby-forum.com/t/gem-update-mysql-issue/59794 "2006-05-07T01:33:22Z")

</div>

I’m trying to do a gem update on my OSX box, and, although it’s always worked fine, lately every time I attempt to do an update , I get faced with the following: sudo gem update Upgrading installed gems… Attempting …

---

## [Numerical Ruby - Segmentation faults, GSL trouble](https://www.ruby-forum.com/t/numerical-ruby-segmentation-faults-gsl-trouble/94557)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 1\
**Last updated:** [May 7, 2006, 1:13am UTC](https://www.ruby-forum.com/t/numerical-ruby-segmentation-faults-gsl-trouble/94557 "2006-05-07T01:13:05Z")

</div>

Dear all, I have to determine the minima of a multiparameter mathematical function numerically. I try to use the simplex method, as implemented in Ruby-Gsl, to do this. Below is some code from an example as given …

---

## [(new to rails) Error on flickr app](https://www.ruby-forum.com/t/new-to-rails-error-on-flickr-app/59783)

<div class="topic-metadata">

**Author:** [@Chris\_Gwynne](https://www.ruby-forum.com/u/Chris_Gwynne)\
**Replies:** 2\
**Last updated:** [May 7, 2006, 1:12am UTC](https://www.ruby-forum.com/t/new-to-rails-error-on-flickr-app/59783 "2006-05-07T01:12:30Z")

</div>

Hi I’m new to rails and am just trying out some tutorials before I delve into it properly. I’m trying to create the flickr app (found in the screencasts section on rubyonrails.com) I’ve built everything according to…

---

## [Self.new and initialize ( was Re: Creating sub-classes using](https://www.ruby-forum.com/t/self-new-and-initialize-was-re-creating-sub-classes-using/59804)

<div class="topic-metadata">

**Author:** [@Bira](https://www.ruby-forum.com/u/Bira)\
**Replies:** 3\
**Last updated:** [May 6, 2006, 11:02pm UTC](https://www.ruby-forum.com/t/self-new-and-initialize-was-re-creating-sub-classes-using/59804 "2006-05-06T23:02:31Z")

</div>

On 5/6/06, Logan C. removed\_email\_address@domain.invalid wrote: @records = \[\] read\_each\_record\_in\_file(file) do |record\_data| record = Database::Record.new extract\_record\_data\_into(record\_data, record…

---

## [Rcov 0.2.0 - code coverage tool for Ruby](https://www.ruby-forum.com/t/rcov-0-2-0-code-coverage-tool-for-ruby/74826)

<div class="topic-metadata">

**Author:** [@tulkas](https://www.ruby-forum.com/u/tulkas)\
**Replies:** 17\
**Last updated:** [May 6, 2006, 10:26pm UTC](https://www.ruby-forum.com/t/rcov-0-2-0-code-coverage-tool-for-ruby/74826 "2006-05-06T22:26:00Z")

</div>

Source code, additional information, screenshots… available at http://eigenclass.org/hiki.rb?rcov Overview rcov is a tool for simple code coverage analysis in Ruby. It improves on the better known coverage\[1\] in a nu…

---

## [Extending Methods](https://www.ruby-forum.com/t/extending-methods/58911)

<div class="topic-metadata">

**Author:** [@minsc](https://www.ruby-forum.com/u/minsc)\
**Replies:** 12\
**Last updated:** [May 6, 2006, 9:43pm UTC](https://www.ruby-forum.com/t/extending-methods/58911 "2006-05-06T21:43:49Z")

</div>

Hello all. I’m working on a plugin system for a IRC client I’m currently making. The current plan is for plugins to extend the base classes of the program. Often a plugin will need to add a little bit of functionality …

---

## [Nitro + Og 0.30.0: VCR mode, Og QBE, Feeds, Fixes](https://www.ruby-forum.com/t/nitro-og-0-30-0-vcr-mode-og-qbe-feeds-fixes/59731)

<div class="topic-metadata">

**Author:** [@gmichelson](https://www.ruby-forum.com/u/gmichelson)\
**Replies:** 5\
**Last updated:** [May 6, 2006, 9:16pm UTC](https://www.ruby-forum.com/t/nitro-og-0-30-0-vcr-mode-og-qbe-feeds-fixes/59731 "2006-05-06T21:16:11Z")

</div>

Dear devs, The Nitro Development Team is proud to announce new versions of Nitro and Og homepage: http://www.nitroproject.org install: gem install nitro download: http://rubyforge.org/projects/nitro/ trac: oree.ch …

---

## [Dumb question - how to get day/month names from a date?](https://www.ruby-forum.com/t/dumb-question-how-to-get-day-month-names-from-a-date/59798)

<div class="topic-metadata">

**Author:** [@adambeazley](https://www.ruby-forum.com/u/adambeazley)\
**Replies:** 1\
**Last updated:** [May 6, 2006, 8:30pm UTC](https://www.ruby-forum.com/t/dumb-question-how-to-get-day-month-names-from-a-date/59798 "2006-05-06T20:30:24Z")

</div>

I can’t for the life of me figure this one out. I know that the Date class has constants including MONTHNAMES and DAYNAMES, but I have no idea how to access them. day = Date.today Date.constants \[“MONTHS”, “ABBR\_DA…

---

## [Second Edition of Agile Web Development with Rails](https://www.ruby-forum.com/t/second-edition-of-agile-web-development-with-rails/94413)

<div class="topic-metadata">

**Author:** [@dirtytree](https://www.ruby-forum.com/u/dirtytree)\
**Replies:** 23\
**Last updated:** [May 6, 2006, 8:27pm UTC](https://www.ruby-forum.com/t/second-edition-of-agile-web-development-with-rails/94413 "2006-05-06T20:27:24Z")

</div>

ANNOUNCING AGILE WEB DEVELOPMENT WITH RAILS, SECOND EDITION http://www.pragmaticprogrammer.com/titles/rails/ Rails has changed a lot since we announced the first edition of the book a year ago. DHH says that the 1.1 r…

---

## [State of Mozilla in Ruby - rbXPCOM, Ruby-Gtk/MozEmbed](https://www.ruby-forum.com/t/state-of-mozilla-in-ruby-rbxpcom-ruby-gtk-mozembed/94548)

<div class="topic-metadata">

**Author:** [@splattael](https://www.ruby-forum.com/u/splattael)\
**Replies:** 6\
**Last updated:** [May 6, 2006, 8:27pm UTC](https://www.ruby-forum.com/t/state-of-mozilla-in-ruby-rbxpcom-ruby-gtk-mozembed/94548 "2006-05-06T20:27:19Z")

</div>

Hello, I have been asking this more times here but did not got even a single answer - not even a ‘we don’t know’ so please this time send me a ‘we don’t know’ at least (I have no clue who should send this, though :win…

---

## [Record good idea?](https://www.ruby-forum.com/t/record-good-idea/94540)

<div class="topic-metadata">

**Author:** [@0ffh](https://www.ruby-forum.com/u/0ffh)\
**Replies:** 5\
**Last updated:** [May 6, 2006, 6:49pm UTC](https://www.ruby-forum.com/t/record-good-idea/94540 "2006-05-06T18:49:35Z")

</div>

Hija! I have made a little record class, because I needed it. Maybe anyone finds this useful, or wants to beat me, because I have overtreaden some unwritten Ruby rule… :-))) ---------------- cut here ---------------…

---

## [Rubyscript2exe a tk app](https://www.ruby-forum.com/t/rubyscript2exe-a-tk-app/59791)

<div class="topic-metadata">

**Author:** [@braas](https://www.ruby-forum.com/u/braas)\
**Replies:** 0\
**Last updated:** [May 6, 2006, 5:46pm UTC](https://www.ruby-forum.com/t/rubyscript2exe-a-tk-app/59791 "2006-05-06T17:46:13Z")

</div>

Hi :slight\_smile: Do anyone know how to create a working exe from a ruby/tk script with rubyscipt2exe? I tried to do it with: ruby rubyscript2exe.rb app.rb --rubyscript2exe-tk I got an exe file but it was not working…

---

## [Generate unique filenames](https://www.ruby-forum.com/t/generate-unique-filenames/59344)

<div class="topic-metadata">

**Author:** [@131313](https://www.ruby-forum.com/u/131313)\
**Replies:** 16\
**Last updated:** [May 6, 2006, 3:26pm UTC](https://www.ruby-forum.com/t/generate-unique-filenames/59344 "2006-05-06T15:26:35Z")

</div>

Hi list, What is the best/easiest way to generate unique filenames ? Couln’t find such method in Ruby :frowning:

---

## [URI parsing barfs on '^'](https://www.ruby-forum.com/t/uri-parsing-barfs-on/94547)

<div class="topic-metadata">

**Author:** [@regularfry](https://www.ruby-forum.com/u/regularfry)\
**Replies:** 2\
**Last updated:** [May 6, 2006, 1:07pm UTC](https://www.ruby-forum.com/t/uri-parsing-barfs-on/94547 "2006-05-06T13:07:42Z")

</div>

Hi there, I’ve got a URL that appears valid, but that URI.parse breaks on. I’m not sure what’s correct here. This URI parses, but is wrong: Symbol lookup from Yahoo Finance This URI doesn’t parse, and is correct: F…

---

## [Comparing objects](https://www.ruby-forum.com/t/comparing-objects/59699)

<div class="topic-metadata">

**Author:** [@markcasio](https://www.ruby-forum.com/u/markcasio)\
**Replies:** 6\
**Last updated:** [May 6, 2006, 12:25pm UTC](https://www.ruby-forum.com/t/comparing-objects/59699 "2006-05-06T12:25:01Z")

</div>

Comparing objects in Ruby can be a little confusing. Let me know if I’ve got this straight. eql? determines whether two object references refer to objects that have the same “value” for example, my\_car.eql?(your\_car…

---

## [Loading data from file with mysql](https://www.ruby-forum.com/t/loading-data-from-file-with-mysql/59778)

<div class="topic-metadata">

**Author:** [@jdruse](https://www.ruby-forum.com/u/jdruse)\
**Replies:** 0\
**Last updated:** [May 6, 2006, 11:59am UTC](https://www.ruby-forum.com/t/loading-data-from-file-with-mysql/59778 "2006-05-06T11:59:48Z")

</div>

I’m trying to load a tab delimited .txt file into a mysql table. I set the OPT\_LOCAL\_INFILE option but the query only reads the first line of the .txt file. If I run the same command as a batch file in mysql the ent…

---

## [Overloading math operations](https://www.ruby-forum.com/t/overloading-math-operations/59765)

<div class="topic-metadata">

**Author:** [@0ffh](https://www.ruby-forum.com/u/0ffh)\
**Replies:** 6\
**Last updated:** [May 6, 2006, 9:06am UTC](https://www.ruby-forum.com/t/overloading-math-operations/59765 "2006-05-06T09:06:09Z")

</div>

Hija, been makin a little “Vector” class by extending Array. Now I wanna add Vector support to the native numeric data types in ruby. Means: Not only Vector+Numeric but also Numeric+Vector should call my + function. …

---

## [Klass.include vs instance.extend question](https://www.ruby-forum.com/t/klass-include-vs-instance-extend-question/59540)

<div class="topic-metadata">

**Author:** [@polypus](https://www.ruby-forum.com/u/polypus)\
**Replies:** 3\
**Last updated:** [May 6, 2006, 7:56am UTC](https://www.ruby-forum.com/t/klass-include-vs-instance-extend-question/59540 "2006-05-06T07:56:03Z")

</div>

i want a few instance methods to be automatically defined for the user without any explicit coding on their part. in the below distillation of my code, i have two options (labelled), my question is whether one option…

---

## [Constant in Ruby](https://www.ruby-forum.com/t/constant-in-ruby/94337)

<div class="topic-metadata">

**Author:** [@charlie](https://www.ruby-forum.com/u/charlie)\
**Replies:** 19\
**Last updated:** [May 6, 2006, 5:25am UTC](https://www.ruby-forum.com/t/constant-in-ruby/94337 "2006-05-06T05:25:11Z")

</div>

I’m new to Ruby programming and I saw this article which concerns me: http://www.bitwisemag.com/copy/features/opinion/ruby/ruby\_debate.html Don’t get me wrong, I love Ruby. But, the idea that a constant is not a const…

---

## [The simplest way to get 1.9 sources?](https://www.ruby-forum.com/t/the-simplest-way-to-get-1-9-sources/59759)

<div class="topic-metadata">

**Author:** [@victor123789](https://www.ruby-forum.com/u/victor123789)\
**Replies:** 2\
**Last updated:** [May 6, 2006, 4:45am UTC](https://www.ruby-forum.com/t/the-simplest-way-to-get-1-9-sources/59759 "2006-05-06T04:45:55Z")

</div>

Hi all. What is the simplest way to get 1.9 sources? I’ve already downloaded binaries, but they was compiled with old versions of visual c++ (so I can’t compile my extensions with my visual c++ 7.1). I have no CVS c…

---

## [Urlgrabber in Ruby](https://www.ruby-forum.com/t/urlgrabber-in-ruby/59753)

<div class="topic-metadata">

**Author:** [@Pau\_Garcia\_i\_Quiles](https://www.ruby-forum.com/u/Pau_Garcia_i_Quiles)\
**Replies:** 1\
**Last updated:** [May 6, 2006, 3:39am UTC](https://www.ruby-forum.com/t/urlgrabber-in-ruby/59753 "2006-05-06T03:39:25Z")

</div>

\-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hello, I’m looking for something like the Python-esque URLGrabber package, but in Ruby. Any tip? urlgrabber is a pure python package that drastically simplifies the f…

---

## [Re: Constant in Ruby](https://www.ruby-forum.com/t/re-constant-in-ruby/94536)

<div class="topic-metadata">

**Author:** [@Gennady\_B](https://www.ruby-forum.com/u/Gennady_B)\
**Replies:** 0\
**Last updated:** [May 6, 2006, 3:39am UTC](https://www.ruby-forum.com/t/re-constant-in-ruby/94536 "2006-05-06T03:39:05Z")

</div>

:slight\_smile: 10 \<\< 20 does bit-wise left shift 20 times. Gennady.

---

## [Re: Bracket Packing (#78)](https://www.ruby-forum.com/t/re-bracket-packing-78/94515)

<div class="topic-metadata">

**Author:** [@stuart\_holden](https://www.ruby-forum.com/u/stuart_holden)\
**Replies:** 5\
**Last updated:** [May 6, 2006, 12:21am UTC](https://www.ruby-forum.com/t/re-bracket-packing-78/94515 "2006-05-06T00:21:45Z")

</div>

Quick question about the phrase ‘occasionally missing off a bracket’. Is it possible to have lost more than one braket missing from the string, or will it be a case of 0…1 brackets missing? I assume just one. If it is…

---

## [Cat2rafb (#77)](https://www.ruby-forum.com/t/cat2rafb-77/94477)

<div class="topic-metadata">

**Author:** [@bbazzarrakk](https://www.ruby-forum.com/u/bbazzarrakk)\
**Replies:** 3\
**Last updated:** [May 5, 2006, 11:04pm UTC](https://www.ruby-forum.com/t/cat2rafb-77/94477 "2006-05-05T23:04:42Z")

</div>

When I first saw this quiz I thought, “I’m going to add this as a command for my text editor!” It was probably a day or two later when I learned that it was already in there and had been for some time now. I guess …

---

## [dRuby connection refused between two different machines](https://www.ruby-forum.com/t/druby-connection-refused-between-two-different-machines/59686)

<div class="topic-metadata">

**Author:** [@Geert\_F](https://www.ruby-forum.com/u/Geert_F)\
**Replies:** 8\
**Last updated:** [May 5, 2006, 10:42pm UTC](https://www.ruby-forum.com/t/druby-connection-refused-between-two-different-machines/59686 "2006-05-05T22:42:48Z")

</div>

Hello, I have been playing with dRuby and am getting strange differences with passing DRbUndumped-objects from a client machine to a DIFFERENT server and calling methods on this object: I wrote a small server that b…

---

## [Newbie question](https://www.ruby-forum.com/t/newbie-question/94512)

<div class="topic-metadata">

**Author:** [@kalons](https://www.ruby-forum.com/u/kalons)\
**Replies:** 8\
**Last updated:** [May 5, 2006, 10:30pm UTC](https://www.ruby-forum.com/t/newbie-question/94512 "2006-05-05T22:30:15Z")

</div>

Given an array like \["&abc", “a&cb”, “b&ac”, “ccc”, “cb&a”\] what is the Ruby way to construct an array containing only elements with duplicate characters following the &'s? In this case \["&abc", “b&ac”, “cb&a”\]

---

## [Big Work Loads & Concurrency](https://www.ruby-forum.com/t/big-work-loads-concurrency/102919)

<div class="topic-metadata">

**Author:** [@dstocks](https://www.ruby-forum.com/u/dstocks)\
**Replies:** 8\
**Last updated:** [May 5, 2006, 9:28pm UTC](https://www.ruby-forum.com/t/big-work-loads-concurrency/102919 "2006-05-05T21:28:04Z")

</div>

I am just learning Ruby and planning a to use it for a network monitoring system. I would like to design a system that will scale well and handle large work loads ( tens of thousands of monitors per server ). My ques…

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

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