# Ruby

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

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

---

## [Faster\_csv vs File+split, why it is not faster?](https://www.ruby-forum.com/t/faster-csv-vs-file-split-why-it-is-not-faster/153842)

<div class="topic-metadata">

**Author:** [@pabloq](https://www.ruby-forum.com/u/pabloq)\
**Replies:** 2\
**Last updated:** [November 21, 2008, 7:28pm UTC](https://www.ruby-forum.com/t/faster-csv-vs-file-split-why-it-is-not-faster/153842 "2008-11-21T19:28:36Z")

</div>

Hi folks, Why I’m getting this result? is It due just to this specif problem? the file has 293858 record, here is some record samples: “MARCOS, LUIS”,“547 N LAKE ST”,"",“MUNDELEIN”,“IL”,“000000000” “BALDWIN, T & S”,…

---

## [Can't install rails with gem](https://www.ruby-forum.com/t/cant-install-rails-with-gem/153793)

<div class="topic-metadata">

**Author:** [@joeymarchy](https://www.ruby-forum.com/u/joeymarchy)\
**Replies:** 4\
**Last updated:** [November 21, 2008, 7:20pm UTC](https://www.ruby-forum.com/t/cant-install-rails-with-gem/153793 "2008-11-21T19:20:01Z")

</div>

joey@lab:~$ gem --version 1.2.0 joey@lab:~$ ruby --version ruby 1.8.7 (2008-08-11 patchlevel 72) \[i486-linux\] When I run: joey@lab:~$ gem install rails ERROR: While executing gem … (Errno::ENOENT) No such file or…

---

## [2 dimensional array to single arrays](https://www.ruby-forum.com/t/2-dimensional-array-to-single-arrays/153827)

<div class="topic-metadata">

**Author:** [@johnnybutler7](https://www.ruby-forum.com/u/johnnybutler7)\
**Replies:** 2\
**Last updated:** [November 21, 2008, 7:14pm UTC](https://www.ruby-forum.com/t/2-dimensional-array-to-single-arrays/153827 "2008-11-21T19:14:49Z")

</div>

Hi, I have a nasty loop which creates 2 single arrays from a 2 dimensional array, is there a quicker way to do it? \[\[“a”,1\],\[“b”,2\],\[“c”,3\]\] So i want an array \[“a”,“b”,“c”\] and \[1,2,3\] Any quick method to do th…

---

## [Weird conversion in IRB](https://www.ruby-forum.com/t/weird-conversion-in-irb/153779)

<div class="topic-metadata">

**Author:** [@nuby2ruby](https://www.ruby-forum.com/u/nuby2ruby)\
**Replies:** 5\
**Last updated:** [November 21, 2008, 6:10pm UTC](https://www.ruby-forum.com/t/weird-conversion-in-irb/153779 "2008-11-21T18:10:29Z")

</div>

For some reason I have this line I am pasting from a text file into IRB, and it is converting the spaces into the word “bee” IFÂ testÂ @yst-hide-felicite irb(main):001:0\> WHENbeeNONEMPTYbee@horizontal-featured-item-te…

---

## [Interesting blog entry on the state of ruby](https://www.ruby-forum.com/t/interesting-blog-entry-on-the-state-of-ruby/153796)

<div class="topic-metadata">

**Author:** [@philswenson](https://www.ruby-forum.com/u/philswenson)\
**Replies:** 13\
**Last updated:** [November 21, 2008, 5:51pm UTC](https://www.ruby-forum.com/t/interesting-blog-entry-on-the-state-of-ruby/153796 "2008-11-21T17:51:15Z")

</div>

I think he dismisses JRuby was too quickly. It seems to me that JRuby is ruby’s best hope for a non-sucky runtime. I’m looking forward to Java 7, my hope is that it results in Ruby running so much better than any …

---

## [Regular Expression help needed](https://www.ruby-forum.com/t/regular-expression-help-needed/153764)

<div class="topic-metadata">

**Author:** [@raju\_k](https://www.ruby-forum.com/u/raju_k)\
**Replies:** 3\
**Last updated:** [November 21, 2008, 3:55pm UTC](https://www.ruby-forum.com/t/regular-expression-help-needed/153764 "2008-11-21T15:55:40Z")

</div>

Hi, I have the following text as a string. Can someone tell me a way to extract the Args array in to different key value pairs as listed in the example ? Request={Identities={ImmedCaller={Name=unknown, SubjectID=abc…

---

## [Syntax question from a newbie to Ruby](https://www.ruby-forum.com/t/syntax-question-from-a-newbie-to-ruby/153577)

<div class="topic-metadata">

**Author:** [@davidstokar](https://www.ruby-forum.com/u/davidstokar)\
**Replies:** 10\
**Last updated:** [November 21, 2008, 3:17pm UTC](https://www.ruby-forum.com/t/syntax-question-from-a-newbie-to-ruby/153577 "2008-11-21T15:17:03Z")

</div>

I am just learning Ruby and I can not seem to see why the first example works but the second one does not - thanks Why does this work: puts ‘Hello what is you’re Favorite Number?’ number = gets.chomp puts’’ puts’-…

---

## [Custom marshal\_dump problems](https://www.ruby-forum.com/t/custom-marshal-dump-problems/153770)

<div class="topic-metadata">

**Author:** [@wolfmanjm](https://www.ruby-forum.com/u/wolfmanjm)\
**Replies:** 1\
**Last updated:** [November 21, 2008, 2:40pm UTC](https://www.ruby-forum.com/t/custom-marshal-dump-problems/153770 "2008-11-21T14:40:23Z")

</div>

I’ve written my own marshal\_dump method for a class, in Java. When it gets called, a ClassCastException is thrown. Here’s the top of the stack trace: java.lang.ClassCastException: org.jruby.RubySymbol at ed.lang.rub…

---

## [TMail now on GitHub](https://www.ruby-forum.com/t/tmail-now-on-github/153816)

<div class="topic-metadata">

**Author:** [@Mikel\_L](https://www.ruby-forum.com/u/Mikel_L)\
**Replies:** 0\
**Last updated:** [November 21, 2008, 1:07pm UTC](https://www.ruby-forum.com/t/tmail-now-on-github/153816 "2008-11-21T13:07:35Z")

</div>

Hello all, I recently (10 minutes ago) put TMail on github. Feel free to join in! Mikel

---

## [Hpricot scraping returns nil](https://www.ruby-forum.com/t/hpricot-scraping-returns-nil/153769)

<div class="topic-metadata">

**Author:** [@bbt](https://www.ruby-forum.com/u/bbt)\
**Replies:** 4\
**Last updated:** [November 21, 2008, 12:38pm UTC](https://www.ruby-forum.com/t/hpricot-scraping-returns-nil/153769 "2008-11-21T12:38:37Z")

</div>

Good evening First I’ll mention I have used the search function and found some useful topics, but I still don’t really find a solution due to a lack of Ruby and Hpricot/Xpath knowlegde. The problem is the following: …

---

## [Method def in method vs method def in block](https://www.ruby-forum.com/t/method-def-in-method-vs-method-def-in-block/153809)

<div class="topic-metadata">

**Author:** [@Kyung\_won\_C](https://www.ruby-forum.com/u/Kyung_won_C)\
**Replies:** 1\
**Last updated:** [November 21, 2008, 10:36am UTC](https://www.ruby-forum.com/t/method-def-in-method-vs-method-def-in-block/153809 "2008-11-21T10:36:04Z")

</div>

class A def aaa puts “called aaa by #{self}” def bbb puts “called bbb by #{self}” end end end a = A.new p a.respond\_to?(:bbb) # =\> false a.aaa p a.respond\_to?(:bbb) # =\> true a.bbb p A.public\_instance\_meth…

---

## [What's the Best Way to Mimic an HTTP Request?](https://www.ruby-forum.com/t/whats-the-best-way-to-mimic-an-http-request/152616)

<div class="topic-metadata">

**Author:** [@danmcb](https://www.ruby-forum.com/u/danmcb)\
**Replies:** 9\
**Last updated:** [November 21, 2008, 10:30am UTC](https://www.ruby-forum.com/t/whats-the-best-way-to-mimic-an-http-request/152616 "2008-11-21T10:30:15Z")

</div>

I’m trying to write a tool that will take a domain as an argument and make a request to http://onsamehost.com and then capture the list of domains that share that same IP. I want to parse out those IPs and put them in…

---

## [Create a md5 / md5 passwd with a salt](https://www.ruby-forum.com/t/create-a-md5-md5-passwd-with-a-salt/153750)

<div class="topic-metadata">

**Author:** [@woodzer](https://www.ruby-forum.com/u/woodzer)\
**Replies:** 6\
**Last updated:** [November 21, 2008, 10:12am UTC](https://www.ruby-forum.com/t/create-a-md5-md5-passwd-with-a-salt/153750 "2008-11-21T10:12:06Z")

</div>

Hi list This problem is so above me my head is swimming. I have a forum software that recently changed the way passwords were stored. I use a ruby script to update the user table when the user changes the password bu…

---

## [Www asiafriendfinder com - Free Online Dating](https://www.ruby-forum.com/t/www-asiafriendfinder-com-free-online-dating/153807)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [November 21, 2008, 9:47am UTC](https://www.ruby-forum.com/t/www-asiafriendfinder-com-free-online-dating/153807 "2008-11-21T09:47:58Z")

</div>

www asiafriendfinder com . . . CLICK HERE\* http://dating365.co.cc/www-asiafriendfinder-com . . . . . . . . . . . . www asiafriendfinder com

---

## [Www jumpdates com - Free Online Dating](https://www.ruby-forum.com/t/www-jumpdates-com-free-online-dating/153806)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [November 21, 2008, 9:41am UTC](https://www.ruby-forum.com/t/www-jumpdates-com-free-online-dating/153806 "2008-11-21T09:41:30Z")

</div>

www jumpdates com . . . CLICK HERE\* http://dating365.co.cc/www-jumpdates-com . . . . . . . . . . . . www jumpdates com

---

## [Notepad++ (no debug output, using XP)](https://www.ruby-forum.com/t/notepad-no-debug-output-using-xp/152928)

<div class="topic-metadata">

**Author:** [@devros](https://www.ruby-forum.com/u/devros)\
**Replies:** 12\
**Last updated:** [November 21, 2008, 8:38am UTC](https://www.ruby-forum.com/t/notepad-no-debug-output-using-xp/152928 "2008-11-21T08:38:14Z")

</div>

Notepad++ seems to be a great editor for Ruby, in XP Windows. However, I don’t see any debug output, and have searched in vain for a solution. Please help or refer me.

---

## [ISMM 2009 Call for Papers](https://www.ruby-forum.com/t/ismm-2009-call-for-papers/153800)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [November 21, 2008, 6:55am UTC](https://www.ruby-forum.com/t/ismm-2009-call-for-papers/153800 "2008-11-21T06:55:51Z")

</div>

International Symposium on Memory Management 2009 http://sysrun.haifa.il.ibm.com/hrl/ISMM2009 CALL FOR PAPERS ISMM is a forum for research in management of dynamically allocated memory. A…

---

## [Network proximity calculation](https://www.ruby-forum.com/t/network-proximity-calculation/153791)

<div class="topic-metadata">

**Author:** [@grayson](https://www.ruby-forum.com/u/grayson)\
**Replies:** 1\
**Last updated:** [November 21, 2008, 5:42am UTC](https://www.ruby-forum.com/t/network-proximity-calculation/153791 "2008-11-21T05:42:43Z")

</div>

Hello, I’m trying to do a home grown load balancing solution that needs to determine which of the two data centers a visitor should be sent to. I’d like to do some type of a network proximity calculation that include…

---

## [Asp.Net MVC is close to Rails or Merb...?](https://www.ruby-forum.com/t/asp-net-mvc-is-close-to-rails-or-merb/153785)

<div class="topic-metadata">

**Author:** [@softmind](https://www.ruby-forum.com/u/softmind)\
**Replies:** 0\
**Last updated:** [November 21, 2008, 2:46am UTC](https://www.ruby-forum.com/t/asp-net-mvc-is-close-to-rails-or-merb/153785 "2008-11-21T02:46:31Z")

</div>

Hi, Since IronRuby is progressing fast, it would be nice to know that Asp.Net MVC resembles more to Rails Or Merb. I would prefer to use IronRuby, Merb and Azure ( Windows Cloud Computing ) in future. Since IronRuby…

---

## [Question about host, gethostbyname and getaddress](https://www.ruby-forum.com/t/question-about-host-gethostbyname-and-getaddress/153639)

<div class="topic-metadata">

**Author:** [@Vladimir\_F](https://www.ruby-forum.com/u/Vladimir_F)\
**Replies:** 10\
**Last updated:** [November 21, 2008, 12:43am UTC](https://www.ruby-forum.com/t/question-about-host-gethostbyname-and-getaddress/153639 "2008-11-21T00:43:14Z")

</div>

Hi \*, Could you pleas help me with following problem ? I need to get FQDN of host as well as it’s IP. So I need same result as “host” command gives me in \*nix OSes. I found out these (suitable) functions: Socket.ge…

---

## [Collect links](https://www.ruby-forum.com/t/collect-links/153767)

<div class="topic-metadata">

**Author:** [@arevert](https://www.ruby-forum.com/u/arevert)\
**Replies:** 0\
**Last updated:** [November 20, 2008, 10:06pm UTC](https://www.ruby-forum.com/t/collect-links/153767 "2008-11-20T22:06:13Z")

</div>

Hi, i have an stupid cuestion, so here it is i need to search something on google, and then collect all the blue links and green urls in the results with Watir. so, my problem is wich property i can use to do this, o…

---

## [Regexp issues](https://www.ruby-forum.com/t/regexp-issues/153761)

<div class="topic-metadata">

**Author:** [@enchanter](https://www.ruby-forum.com/u/enchanter)\
**Replies:** 3\
**Last updated:** [November 20, 2008, 9:53pm UTC](https://www.ruby-forum.com/t/regexp-issues/153761 "2008-11-20T21:53:22Z")

</div>

http://pastie.org/319919 On line 42, I get an error that there is no function ‘\[\]’ for nil:Nilclass… am I just missing something extremely obvious?

---

## [Array.include? with a regex?](https://www.ruby-forum.com/t/array-include-with-a-regex/153752)

<div class="topic-metadata">

**Author:** [@spacechurro](https://www.ruby-forum.com/u/spacechurro)\
**Replies:** 5\
**Last updated:** [November 20, 2008, 9:41pm UTC](https://www.ruby-forum.com/t/array-include-with-a-regex/153752 "2008-11-20T21:41:46Z")

</div>

i am wondering if this is possible… i can’t seem to figure it out… i am trying to see if a value is inside an array using regex… something like: a = \[“pie”,“cookies”,“soda”,“icecream”\] i want to see if something star…

---

## [BFS in ruby from a hash](https://www.ruby-forum.com/t/bfs-in-ruby-from-a-hash/153687)

<div class="topic-metadata">

**Author:** [@equinox](https://www.ruby-forum.com/u/equinox)\
**Replies:** 8\
**Last updated:** [November 20, 2008, 9:01pm UTC](https://www.ruby-forum.com/t/bfs-in-ruby-from-a-hash/153687 "2008-11-20T21:01:02Z")

</div>

I want to do a breadth first search on a hash like below: http://pastie.org/319366 can anyone give me some idea where to start as I’ve never done bfs (breadth first search) on hash before.

---

## [Trouble with Readline and Building Ruby 1.9](https://www.ruby-forum.com/t/trouble-with-readline-and-building-ruby-1-9/124110)

<div class="topic-metadata">

**Author:** [@sjames](https://www.ruby-forum.com/u/sjames)\
**Replies:** 13\
**Last updated:** [November 20, 2008, 8:52pm UTC](https://www.ruby-forum.com/t/trouble-with-readline-and-building-ruby-1-9/124110 "2008-11-20T20:52:34Z")

</div>

I’m having a little trouble building Ruby 1.9. I’m building on Leopard and using “–prefix=/usr/local/ruby1.9” when running config, but I’m getting the following output after running ‘make’: gcc -I. -I…/…/.ext/include…

---

## [Code Review: RubyInitializers8](https://www.ruby-forum.com/t/code-review-rubyinitializers8/153746)

<div class="topic-metadata">

**Author:** [@grujildo](https://www.ruby-forum.com/u/grujildo)\
**Replies:** 1\
**Last updated:** [November 20, 2008, 8:02pm UTC](https://www.ruby-forum.com/t/code-review-rubyinitializers8/153746 "2008-11-20T20:02:04Z")

</div>

tfpt review “/shelveset:RubyInitializers8;REDMOND\\tomat” Comment : Refactors call actions, reimplements calls to constructors, allocators and initializers. Implements allocate operation for built-in classes (where a…

---

## [ANN: One-Click Ruby Installer 186-27 Release Candidate 2](https://www.ruby-forum.com/t/ann-one-click-ruby-installer-186-27-release-candidate-2/153675)

<div class="topic-metadata">

**Author:** [@luislavena](https://www.ruby-forum.com/u/luislavena)\
**Replies:** 10\
**Last updated:** [November 20, 2008, 7:25pm UTC](https://www.ruby-forum.com/t/ann-one-click-ruby-installer-186-27-release-candidate-2/153675 "2008-11-20T19:25:33Z")

</div>

Hello Ruby for Windows users! At last second release candidate of 186-27 got released. First I’ll like to explain why this took so long: When preparing this release (RC2), release 1.3.0 of RubyGems turned completely …

---

## [Passing objects from Java to JRuby and back](https://www.ruby-forum.com/t/passing-objects-from-java-to-jruby-and-back/153739)

<div class="topic-metadata">

**Author:** [@cage](https://www.ruby-forum.com/u/cage)\
**Replies:** 0\
**Last updated:** [November 20, 2008, 6:13pm UTC](https://www.ruby-forum.com/t/passing-objects-from-java-to-jruby-and-back/153739 "2008-11-20T18:13:02Z")

</div>

Hello ! I hope my question isn’t too trivial for you guys . Let’s say I have a HashTable which I would like to populate from a ruby method . Is there any way to pass the HashTable as a parameter to evalScriptlet ? Or …

---

## [How to get an absolute link from WWW::Mechanize](https://www.ruby-forum.com/t/how-to-get-an-absolute-link-from-www-mechanize/153737)

<div class="topic-metadata">

**Author:** [@cage](https://www.ruby-forum.com/u/cage)\
**Replies:** 0\
**Last updated:** [November 20, 2008, 5:51pm UTC](https://www.ruby-forum.com/t/how-to-get-an-absolute-link-from-www-mechanize/153737 "2008-11-20T17:51:51Z")

</div>

Hello ! I noticed links in mechanize have an absolute? method , which tells me if a link is absolute or not , but not an option to\_absolute . I would like to avoid the following : mech.get(some\_link) puts mech.page.…

---

## [Finding and writing to specified area in a text file](https://www.ruby-forum.com/t/finding-and-writing-to-specified-area-in-a-text-file/153326)

<div class="topic-metadata">

**Author:** [@rmac217](https://www.ruby-forum.com/u/rmac217)\
**Replies:** 4\
**Last updated:** [November 20, 2008, 5:51pm UTC](https://www.ruby-forum.com/t/finding-and-writing-to-specified-area-in-a-text-file/153326 "2008-11-20T17:51:23Z")

</div>

Hello, I’m trying to find a specified keyword in a text file that I have open then replace the line of that keyword with some new text. Is it possible do do this? So something like: #custom.txt hello world INSERT …

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

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