# Ruby

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

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

---

## [Dynamic detection of bang and question methods](https://www.ruby-forum.com/t/dynamic-detection-of-bang-and-question-methods/114988)

<div class="topic-metadata">

**Author:** [@leethal](https://www.ruby-forum.com/u/leethal)\
**Replies:** 4\
**Last updated:** [September 20, 2007, 8:07pm UTC](https://www.ruby-forum.com/t/dynamic-detection-of-bang-and-question-methods/114988 "2007-09-20T20:07:00Z")

</div>

I got this idea of a sort of neat syntatic sugar of bang (foo!) and question (foo?) methods. Take a look at this pastie: http://pastie.caboo.se/98638 The idea is that you’ll have two keywords added to Ruby - bang\_give…

---

## [Ruby parser wierdness?](https://www.ruby-forum.com/t/ruby-parser-wierdness/115115)

<div class="topic-metadata">

**Author:** [@ciconia](https://www.ruby-forum.com/u/ciconia)\
**Replies:** 1\
**Last updated:** [September 20, 2007, 7:39pm UTC](https://www.ruby-forum.com/t/ruby-parser-wierdness/115115 "2007-09-20T19:39:13Z")

</div>

Hi gang I’ve stumbled upon a weird phenomenon when trying nested Dataset#query methods with Sequel: ds = DB\[:items\].query do select :x, :y where :x =\> DB\[:stuff\].query do select :a where :b =\> DB\[:misc\].query do …

---

## [Storing a search index on the filesystem](https://www.ruby-forum.com/t/storing-a-search-index-on-the-filesystem/115116)

<div class="topic-metadata">

**Author:** [@dougal](https://www.ruby-forum.com/u/dougal)\
**Replies:** 0\
**Last updated:** [September 20, 2007, 7:07pm UTC](https://www.ruby-forum.com/t/storing-a-search-index-on-the-filesystem/115116 "2007-09-20T19:07:01Z")

</div>

Hi Folks. I’ve recently been working on a search plugin for Rails. It’s going well, but I wondered if there was a better way to store the index than my current method. The top level of the index is basically a hash w…

---

## [Using the newest Ruby after installing Locomotive](https://www.ruby-forum.com/t/using-the-newest-ruby-after-installing-locomotive/115113)

<div class="topic-metadata">

**Author:** [@winterheat](https://www.ruby-forum.com/u/winterheat)\
**Replies:** 1\
**Last updated:** [September 20, 2007, 6:59pm UTC](https://www.ruby-forum.com/t/using-the-newest-ruby-after-installing-locomotive/115113 "2007-09-20T18:59:59Z")

</div>

after installing Locomotive on Mac, both the shell (Terminal) and TextMate still would run with the Ruby 1.8.2 that shipped with the Mac. I wonder how it would be to make the shell and Textmate work with 1.8.6 that ca…

---

## [A patch for ruby-dbi mysql - fixes problem with stored procs](https://www.ruby-forum.com/t/a-patch-for-ruby-dbi-mysql-fixes-problem-with-stored-procs/115111)

<div class="topic-metadata">

**Author:** [@roa](https://www.ruby-forum.com/u/roa)\
**Replies:** 0\
**Last updated:** [September 20, 2007, 6:20pm UTC](https://www.ruby-forum.com/t/a-patch-for-ruby-dbi-mysql-fixes-problem-with-stored-procs/115111 "2007-09-20T18:20:20Z")

</div>

Append “mysql\_client\_multi\_results=1” to your DSN, like this: @dbh = DBI.connect(“DBI:Mysql:database=mydatabase;host=localhost;mysql\_client\_multi\_results=1”, “root”, “password”)

---

## [Apriori algorithm](https://www.ruby-forum.com/t/apriori-algorithm/115100)

<div class="topic-metadata">

**Author:** [@jtibu](https://www.ruby-forum.com/u/jtibu)\
**Replies:** 0\
**Last updated:** [September 20, 2007, 4:21pm UTC](https://www.ruby-forum.com/t/apriori-algorithm/115100 "2007-09-20T16:21:50Z")

</div>

Hi there folks! I’m wondering if anyone has already implemented the Apriori algorithm (http://en.wikipedia.org/wiki/Apriori\_algorithm) using Ruby? Thanks

---

## [This is general Questions?](https://www.ruby-forum.com/t/this-is-general-questions/115068)

<div class="topic-metadata">

**Author:** [@vellingiri](https://www.ruby-forum.com/u/vellingiri)\
**Replies:** 5\
**Last updated:** [September 20, 2007, 4:10pm UTC](https://www.ruby-forum.com/t/this-is-general-questions/115068 "2007-09-20T16:10:34Z")

</div>

Dear Friends, Where can I get the ls source code. Please anyboby already aware means that tell to me. I have been searching since two days,but I was unable to get the clear source code of ls. anyone help me. by Ve…

---

## [Hash value of { n =\> n }](https://www.ruby-forum.com/t/hash-value-of-n-n/115097)

<div class="topic-metadata">

**Author:** [@Yusuke\_ENDOH](https://www.ruby-forum.com/u/Yusuke_ENDOH)\
**Replies:** 0\
**Last updated:** [September 20, 2007, 3:59pm UTC](https://www.ruby-forum.com/t/hash-value-of-n-n/115097 "2007-09-20T15:59:30Z")

</div>

e$B1sF#$H?=$7$^$9e(B 1.9 e$B$G0J2\<$N%3!\<%I$r\<B9T$9$k$H!"$+$J$j;~4V$,$+$+$j$^$9!#e(B $ time ./ruby -ve ‘h = {}; 10000.times {|x| h\[{ x =\> x }\] = 1 }’ ruby 1.9.0 (2007-09-15 patchlevel 0) \[i686-linux\] real 0m12.369s …

---

## [Uniforma 0.0.2 released](https://www.ruby-forum.com/t/uniforma-0-0-2-released/115094)

<div class="topic-metadata">

**Author:** [@Victor\_SZverokSS\_Sh](https://www.ruby-forum.com/u/Victor_SZverokSS_Sh)\
**Replies:** 0\
**Last updated:** [September 20, 2007, 3:40pm UTC](https://www.ruby-forum.com/t/uniforma-0-0-2-released/115094 "2007-09-20T15:40:26Z")

</div>

Hello all. Subj at http://uniforma.rubyforge.org == DESCRIPTION: Uniforma is a library for parsing text formats and convert them to other formats. The main goal of library design was to make text parser/generator d…

---

## [(no subject)](https://www.ruby-forum.com/t/no-subject/115091)

<div class="topic-metadata">

**Author:** [@jhonny](https://www.ruby-forum.com/u/jhonny)\
**Replies:** 0\
**Last updated:** [September 20, 2007, 3:18pm UTC](https://www.ruby-forum.com/t/no-subject/115091 "2007-09-20T15:18:19Z")

</div>

unsubscribe

---

## [Standard library manpages for v1.8.5](https://www.ruby-forum.com/t/standard-library-manpages-for-v1-8-5/115085)

<div class="topic-metadata">

**Author:** [@bigdaddy71](https://www.ruby-forum.com/u/bigdaddy71)\
**Replies:** 1\
**Last updated:** [September 20, 2007, 2:45pm UTC](https://www.ruby-forum.com/t/standard-library-manpages-for-v1-8-5/115085 "2007-09-20T14:45:11Z")

</div>

I am running Ruby 1.8.5 on OpenBSD 4.1. and trying to access Ruby standard library documentation in manpage format but have not found any. I know I can access this via the website but I prefer not to and prefer manpag…

---

## [YAML & readlines & modify text files](https://www.ruby-forum.com/t/yaml-readlines-modify-text-files/114989)

<div class="topic-metadata">

**Author:** [@dcgrigsby](https://www.ruby-forum.com/u/dcgrigsby)\
**Replies:** 15\
**Last updated:** [September 20, 2007, 2:41pm UTC](https://www.ruby-forum.com/t/yaml-readlines-modify-text-files/114989 "2007-09-20T14:41:10Z")

</div>

Hello, Can anyone help me with the following issue: I have a YAML file that looks like this: gm: Name01 gs: N01 gm: Name02 gs: N02 In ruby I’m trying to read all \*.txt files in the current folder and all sub-fold…

---

## [IP to Country (#139)](https://www.ruby-forum.com/t/ip-to-country-139/115086)

<div class="topic-metadata">

**Author:** [@bbazzarrakk](https://www.ruby-forum.com/u/bbazzarrakk)\
**Replies:** 0\
**Last updated:** [September 20, 2007, 2:19pm UTC](https://www.ruby-forum.com/t/ip-to-country-139/115086 "2007-09-20T14:19:07Z")

</div>

Matthias WÃ¤tcher made a classic mistake this week. He sent in his first ever quiz solution and told us not to expect anything special out of it. We later learned that it was a lot faster than all of the other solu…

---

## [Re: how can I remove all the comments in my c program](https://www.ruby-forum.com/t/re-how-can-i-remove-all-the-comments-in-my-c-program/115077)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [September 20, 2007, 12:30pm UTC](https://www.ruby-forum.com/t/re-how-can-i-remove-all-the-comments-in-my-c-program/115077 "2007-09-20T12:30:49Z")

</div>

I would say that if you had been open about your reasons for wanting to remove the comments from the C code then you would have got a better reception. You still haven’t given a clear and open reason for doing this, i…

---

## [Getting associations list](https://www.ruby-forum.com/t/getting-associations-list/115073)

<div class="topic-metadata">

**Author:** [@akiross](https://www.ruby-forum.com/u/akiross)\
**Replies:** 1\
**Last updated:** [September 20, 2007, 12:25pm UTC](https://www.ruby-forum.com/t/getting-associations-list/115073 "2007-09-20T12:25:48Z")

</div>

Hi there, how can I retrieve a list of associations for a given Active Record? I mean, having: class Foo \< ActiveRecord::Base has\_one :bar has\_one :baz belongs\_to :gosh belongs\_to :gulp end get lists of all has\_…

---

## [Thread switching? (p. 144 pickaxe2)](https://www.ruby-forum.com/t/thread-switching-p-144-pickaxe2/115053)

<div class="topic-metadata">

**Author:** [@7stud](https://www.ruby-forum.com/u/7stud)\
**Replies:** 1\
**Last updated:** [September 20, 2007, 12:24pm UTC](https://www.ruby-forum.com/t/thread-switching-p-144-pickaxe2/115053 "2007-09-20T12:24:48Z")

</div>

Hi, On p. 144 in pickaxe2, there are two examples using threads(see below). Each thread updates a counter, and the function call that updates the counter is synchronized to prevent simultaneous axis to the counter. P…

---

## [Lignhtning fast autocompleter IE issue (script save call)](https://www.ruby-forum.com/t/lignhtning-fast-autocompleter-ie-issue-script-save-call/115071)

<div class="topic-metadata">

**Author:** [@jhonny](https://www.ruby-forum.com/u/jhonny)\
**Replies:** 1\
**Last updated:** [September 20, 2007, 11:31am UTC](https://www.ruby-forum.com/t/lignhtning-fast-autocompleter-ie-issue-script-save-call/115071 "2007-09-20T11:31:39Z")

</div>

Hi friends, I was using the rails recipes for the feature called Lightning fast auto completer where we search and save the contents to be displayed in the JavaScript Array . something like in some .js file var auth…

---

## [Lignhtning fast autocompleter IE issue](https://www.ruby-forum.com/t/lignhtning-fast-autocompleter-ie-issue/115070)

<div class="topic-metadata">

**Author:** [@jhonny](https://www.ruby-forum.com/u/jhonny)\
**Replies:** 0\
**Last updated:** [September 20, 2007, 11:19am UTC](https://www.ruby-forum.com/t/lignhtning-fast-autocompleter-ie-issue/115070 "2007-09-20T11:19:37Z")

</div>

Hi friends, I was using the rails recipes for the feature called Lightning fast auto completer where we search and save the contents to be displayed in the JavaScript Array . something like in some .js file var auth…

---

## [In ruby/tk how to hide and unhide a root window](https://www.ruby-forum.com/t/in-ruby-tk-how-to-hide-and-unhide-a-root-window/115047)

<div class="topic-metadata">

**Author:** [@Ed\_Redman](https://www.ruby-forum.com/u/Ed_Redman)\
**Replies:** 1\
**Last updated:** [September 20, 2007, 11:16am UTC](https://www.ruby-forum.com/t/in-ruby-tk-how-to-hide-and-unhide-a-root-window/115047 "2007-09-20T11:16:37Z")

</div>

I have discovered how to hide a root window ie root.withdraw question is how do I unhide the root window? thanks in advance

---

## [How can I connect ruby with postgreSQL](https://www.ruby-forum.com/t/how-can-i-connect-ruby-with-postgresql/114974)

<div class="topic-metadata">

**Author:** [@vellingiri](https://www.ruby-forum.com/u/vellingiri)\
**Replies:** 3\
**Last updated:** [September 20, 2007, 11:13am UTC](https://www.ruby-forum.com/t/how-can-i-connect-ruby-with-postgresql/114974 "2007-09-20T11:13:37Z")

</div>

Dear Friends, how can I connect ruby with postgreSQL. Please give some procedure. how can I install the proper packages and what are the configurations I am going to made. what are the steps I have to follow that’s …

---

## [ParseTree 2.0.2 Released](https://www.ruby-forum.com/t/parsetree-2-0-2-released/115066)

<div class="topic-metadata">

**Author:** [@aguynamedryan](https://www.ruby-forum.com/u/aguynamedryan)\
**Replies:** 0\
**Last updated:** [September 20, 2007, 10:14am UTC](https://www.ruby-forum.com/t/parsetree-2-0-2-released/115066 "2007-09-20T10:14:29Z")

</div>

ParseTree version 2.0.2 has been released! http://www.zenspider.com/ZSS/Products/ParseTree/ ParseTree is a C extension (using RubyInline) that extracts the parse tree for an entire class or a specific method and retu…

---

## [Re: IP to Country (#139)](https://www.ruby-forum.com/t/re-ip-to-country-139/115058)

<div class="topic-metadata">

**Author:** [@steve\_d](https://www.ruby-forum.com/u/steve_d)\
**Replies:** 1\
**Last updated:** [September 20, 2007, 10:03am UTC](https://www.ruby-forum.com/t/re-ip-to-country-139/115058 "2007-09-20T10:03:28Z")

</div>

From: Bill K. removed\_email\_address@domain.invalid Cool. I guess mine was overlooked but it also does no prep work: Sorry about that, re-ran with yours included: 10000 times each: -bash-2.05b$ ruby bm.rb sorted b…

---

## [Special Array method about Unix pathes](https://www.ruby-forum.com/t/special-array-method-about-unix-pathes/115010)

<div class="topic-metadata">

**Author:** [@Une\_BSSSSvS\_ue](https://www.ruby-forum.com/u/Une_BSSSSvS_ue)\
**Replies:** 14\
**Last updated:** [September 20, 2007, 7:46am UTC](https://www.ruby-forum.com/t/special-array-method-about-unix-pathes/115010 "2007-09-20T07:46:12Z")

</div>

here is the goal: i’ve an Array of Unix pathes : forbidden = \["/Volumes/U3 System", “/Volumes/EMTEC KEY/emtec\_dl”, “/Volumes/EMTEC KEY/emtec\_dl/Win98SE new driver.exe”, “/Volumes/EMTEC KEY/emtec\_dl/v233r001” \] i w…

---

## [Scraping web pages for cisco products](https://www.ruby-forum.com/t/scraping-web-pages-for-cisco-products/115017)

<div class="topic-metadata">

**Author:** [@animate123](https://www.ruby-forum.com/u/animate123)\
**Replies:** 14\
**Last updated:** [September 20, 2007, 7:36am UTC](https://www.ruby-forum.com/t/scraping-web-pages-for-cisco-products/115017 "2007-09-20T07:36:53Z")

</div>

I submitted a post a few days ago about scraping the web for Cisco products. I didn’t receive that much input so I thought I would ask again. Here are the requirments. I have a list of 2000 urls that all have Cisco in…

---

## [Re: IP to Country (#139)](https://www.ruby-forum.com/t/re-ip-to-country-139/115050)

<div class="topic-metadata">

**Author:** [@steve\_d](https://www.ruby-forum.com/u/steve_d)\
**Replies:** 1\
**Last updated:** [September 20, 2007, 7:01am UTC](https://www.ruby-forum.com/t/re-ip-to-country-139/115050 "2007-09-20T07:01:09Z")

</div>

I did some benchmarking of my own. This one tests out the performance of a single lookup. I only ran this on solutions which work with IpToCountry.csv out of the box (aka do no prep work). This benchmark ran each so…

---

## [Drb Timeout issues](https://www.ruby-forum.com/t/drb-timeout-issues/115055)

<div class="topic-metadata">

**Author:** [@daxlnc](https://www.ruby-forum.com/u/daxlnc)\
**Replies:** 0\
**Last updated:** [September 20, 2007, 6:39am UTC](https://www.ruby-forum.com/t/drb-timeout-issues/115055 "2007-09-20T06:39:21Z")

</div>

All, I am using drb to query server information from a client. My issue is when the client gets the server object and begins querying information, if the server shuts down or loses a it ip address, the client wait for …

---

## [ANN: RubyGems 0.9.3 Released](https://www.ruby-forum.com/t/ann-rubygems-0-9-3-released/103902)

<div class="topic-metadata">

**Author:** [@jimweirich](https://www.ruby-forum.com/u/jimweirich)\
**Replies:** 9\
**Last updated:** [September 20, 2007, 5:02am UTC](https://www.ruby-forum.com/t/ann-rubygems-0-9-3-released/103902 "2007-09-20T05:02:03Z")

</div>

= Announce: RubyGems Release 0.9.3 Release 0.9.3 is a maintenance release of RubyGems that fixes a problem with ZLib on Windows playforms. If you are experiencing “Buffer Error” problems with RubyGems, we recommend u…

---

## [Irb Failing](https://www.ruby-forum.com/t/irb-failing/115039)

<div class="topic-metadata">

**Author:** [@Ari\_B](https://www.ruby-forum.com/u/Ari_B)\
**Replies:** 0\
**Last updated:** [September 20, 2007, 1:13am UTC](https://www.ruby-forum.com/t/irb-failing/115039 "2007-09-20T01:13:40Z")

</div>

Hey everyone So let me begin my story… I wanted to be awesome in my own mind, so I decided to learn to program ruby. I installed ruby from source on my mac into /usr/local/ bin and everything went dandy. IRB, erb, rd…

---

## [Capturing access to array elements](https://www.ruby-forum.com/t/capturing-access-to-array-elements/114911)

<div class="topic-metadata">

**Author:** [@mortee](https://www.ruby-forum.com/u/mortee)\
**Replies:** 9\
**Last updated:** [September 19, 2007, 11:55pm UTC](https://www.ruby-forum.com/t/capturing-access-to-array-elements/114911 "2007-09-19T23:55:33Z")

</div>

Hi, my question may sound a bit amateur, but I’m just starting to play around with Ruby. So which methods in Array do I have to override, if I want to make sure I can capture any attempt to access an array element? I…

---

## [Exceptions and eval'ing a string](https://www.ruby-forum.com/t/exceptions-and-evaling-a-string/115019)

<div class="topic-metadata">

**Author:** [@bigdaddy71](https://www.ruby-forum.com/u/bigdaddy71)\
**Replies:** 3\
**Last updated:** [September 19, 2007, 11:00pm UTC](https://www.ruby-forum.com/t/exceptions-and-evaling-a-string/115019 "2007-09-19T23:00:25Z")

</div>

Here’s my situation I have a setup such as: ----task.rb---- class Task def initialize(name, &action) @name = name @action = action end def run @action.call(self) end end ----task\_runner.rb---- require ‘task’ …

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

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