# Ruby

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

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

---

## [Debugging a cgi](https://www.ruby-forum.com/t/debugging-a-cgi/48618)

<div class="topic-metadata">

**Author:** [@maggelet](https://www.ruby-forum.com/u/maggelet)\
**Replies:** 7\
**Last updated:** [November 23, 2005, 9:04pm UTC](https://www.ruby-forum.com/t/debugging-a-cgi/48618 "2005-11-23T21:04:50Z")

</div>

Hi, Is there a good way to get more information about what went wrong in a ruby cgi script than just a 500 error page? I know I could run it from a shell but this isn’t always an option. I’m running as cgi on apache. …

---

## [Is there shape drawing tool (like PHP) in Ruby?](https://www.ruby-forum.com/t/is-there-shape-drawing-tool-like-php-in-ruby/48716)

<div class="topic-metadata">

**Author:** [@ricrsskim](https://www.ruby-forum.com/u/ricrsskim)\
**Replies:** 3\
**Last updated:** [November 23, 2005, 9:04pm UTC](https://www.ruby-forum.com/t/is-there-shape-drawing-tool-like-php-in-ruby/48716 "2005-11-23T21:04:50Z")

</div>

I need to draw a simple graphs to post my biological data on web. And I also want to add some interactivity into the graph (using like a simiple imagemap). To do this, I need to know the position of squares or circle…

---

## [Re: Is there shape drawing tool (like PHP) in Ruby? I don't](https://www.ruby-forum.com/t/re-is-there-shape-drawing-tool-like-php-in-ruby-i-dont/48714)

<div class="topic-metadata">

**Author:** [@sskim.box](https://www.ruby-forum.com/u/sskim.box)\
**Replies:** 3\
**Last updated:** [November 23, 2005, 9:00pm UTC](https://www.ruby-forum.com/t/re-is-there-shape-drawing-tool-like-php-in-ruby-i-dont/48714 "2005-11-23T21:00:48Z")

</div>

It was a great information that it is possible to use SVG in Ruby. Thanks for that. :slight\_smile: But, I don’t want to require users to install plug-ins. And I don’t need any vector feature. What I need is a simple …

---

## [OT: Micro benchmarks (Was: How convert an integer to a bit a](https://www.ruby-forum.com/t/ot-micro-benchmarks-was-how-convert-an-integer-to-a-bit-a/49868)

<div class="topic-metadata">

**Author:** [@Daniel.Berger](https://www.ruby-forum.com/u/Daniel.Berger)\
**Replies:** 1\
**Last updated:** [November 23, 2005, 8:56pm UTC](https://www.ruby-forum.com/t/ot-micro-benchmarks-was-how-convert-an-integer-to-a-bit-a/49868 "2005-11-23T20:56:46Z")

</div>

\-----Original Message----- From: Curt H. \[mailto:removed\_email\_address@domain.invalid\] Sent: Wednesday, November 23, 2005 11:28 AM To: ruby-talk ML Subject: Re: How convert an integer to a bit array Cool! Thank…

---

## [Teaching ruby as cs intro?](https://www.ruby-forum.com/t/teaching-ruby-as-cs-intro/48681)

<div class="topic-metadata">

**Author:** [@michael.schwab](https://www.ruby-forum.com/u/michael.schwab)\
**Replies:** 13\
**Last updated:** [November 23, 2005, 8:00pm UTC](https://www.ruby-forum.com/t/teaching-ruby-as-cs-intro/48681 "2005-11-23T20:00:17Z")

</div>

My school teaches intro to programming with Java or C#, intro to cs with Scheme, then requires two semesters of C to scare us into being good and careful. Learning about Ruby has been a way nicer experience and I thi…

---

## [Net/smtp question](https://www.ruby-forum.com/t/net-smtp-question/52953)

<div class="topic-metadata">

**Author:** [@itsme213](https://www.ruby-forum.com/u/itsme213)\
**Replies:** 4\
**Last updated:** [November 23, 2005, 8:00pm UTC](https://www.ruby-forum.com/t/net-smtp-question/52953 "2005-11-23T20:00:17Z")

</div>

I am experimenting with SMTP mail from my local machine, to basically send an email just like my Outlook client does. But I can’t figure out how to translate my Outlook settings to the parameters of SMTP.start, in pa…

---

## [Alias\_method, return new name instead of class](https://www.ruby-forum.com/t/alias-method-return-new-name-instead-of-class/48715)

<div class="topic-metadata">

**Author:** [@transfire](https://www.ruby-forum.com/u/transfire)\
**Replies:** 0\
**Last updated:** [November 23, 2005, 7:48pm UTC](https://www.ruby-forum.com/t/alias-method-return-new-name-instead-of-class/48715 "2005-11-23T19:48:11Z")

</div>

Might be nice is #alias\_method returned the new method name so that one could do: private alias\_method( :foo, :bar ) b/c private alias\_method :foo, :bar doesn’t work. Right now it appears to return the class/modul…

---

## [Re: string range membership](https://www.ruby-forum.com/t/re-string-range-membership/100720)

<div class="topic-metadata">

**Author:** [@warrenbrown](https://www.ruby-forum.com/u/warrenbrown)\
**Replies:** 2\
**Last updated:** [November 23, 2005, 7:28pm UTC](https://www.ruby-forum.com/t/re-string-range-membership/100720 "2005-11-23T19:28:02Z")

</div>

Ara, ruby -v -e “p((‘1’…‘10’).to\_a)” ruby 1.8.2 (2004-12-25) \[i386-mswin32\] \[“1”, “2”, “3”, “4”, “5”, “6”, “7”, “8”, “9”, “10”\] This shows a clear and unique mapping of the range ‘1’…‘10’ into a set of strings. b…

---

## [/usr/bin/gem:3:in \`require': no such file to load](https://www.ruby-forum.com/t/usr-bin-gemin-require-no-such-file-to-load/49630)

<div class="topic-metadata">

**Author:** [@nospam2](https://www.ruby-forum.com/u/nospam2)\
**Replies:** 3\
**Last updated:** [November 23, 2005, 6:55pm UTC](https://www.ruby-forum.com/t/usr-bin-gemin-require-no-such-file-to-load/49630 "2005-11-23T18:55:42Z")

</div>

Ok, I removed Ruby 1.8-2 and installed Ruby 1.8-3 from source (./configure, make, make install). Everything seemed to be fine until I tried to start gem that I previously installed. Now gem tells me: /usr/bin/gem:3:in…

---

## [Rails w/ fast-cgi](https://www.ruby-forum.com/t/rails-w-fast-cgi/48601)

<div class="topic-metadata">

**Author:** [@stakadush](https://www.ruby-forum.com/u/stakadush)\
**Replies:** 1\
**Last updated:** [November 23, 2005, 5:14pm UTC](https://www.ruby-forum.com/t/rails-w-fast-cgi/48601 "2005-11-23T17:14:47Z")

</div>

i give up :slight\_smile: i read every possible page on this…hope someone will have answer here… can’t seem to make rails with fastcgi run on ensim (fedora) server. runs nicely on my os x. did everything said. even t…

---

## [Re: getting stdout and stderr for system calls on windows](https://www.ruby-forum.com/t/re-getting-stdout-and-stderr-for-system-calls-on-windows/52998)

<div class="topic-metadata">

**Author:** [@Daniel.Berger](https://www.ruby-forum.com/u/Daniel.Berger)\
**Replies:** 0\
**Last updated:** [November 23, 2005, 5:14pm UTC](https://www.ruby-forum.com/t/re-getting-stdout-and-stderr-for-system-calls-on-windows/52998 "2005-11-23T17:14:47Z")

</div>

want to capture stdout and stderr as well as the return value from dmake. Normally I would do it using Daniel B.'s win32-popen3, but I have a Windows Installer Ruby with VC++6.0 which nastily gives me a segfault (pr…

---

## [Re: Euchre Hands (#55)](https://www.ruby-forum.com/t/re-euchre-hands-55/49747)

<div class="topic-metadata">

**Author:** [@warrenbrown](https://www.ruby-forum.com/u/warrenbrown)\
**Replies:** 1\
**Last updated:** [November 23, 2005, 4:58pm UTC](https://www.ruby-forum.com/t/re-euchre-hands-55/49747 "2005-11-23T16:58:42Z")

</div>

James, initial suit order for each player and holds that until the hand is played out (even if black/red suits eventually touch). Note that you will have to order the hand twice though, once after the deal and onc…

---

## [Re: string range membership](https://www.ruby-forum.com/t/re-string-range-membership/100716)

<div class="topic-metadata">

**Author:** [@warrenbrown](https://www.ruby-forum.com/u/warrenbrown)\
**Replies:** 3\
**Last updated:** [November 23, 2005, 4:30pm UTC](https://www.ruby-forum.com/t/re-string-range-membership/100716 "2005-11-23T16:30:27Z")

</div>

Brian, I’d argue that it is not a bug, as there is no unique isomorphie from strings to integers. I have to disagree. ruby -v -e “p((‘1’…‘10’).to\_a)” ruby 1.8.2 (2004-12-25) \[i386-mswin32\] \[“1”, “2”, “3”, “4”, “…

---

## [Using hashes as keys in hashes](https://www.ruby-forum.com/t/using-hashes-as-keys-in-hashes/48688)

<div class="topic-metadata">

**Author:** [@stevena](https://www.ruby-forum.com/u/stevena)\
**Replies:** 3\
**Last updated:** [November 23, 2005, 4:26pm UTC](https://www.ruby-forum.com/t/using-hashes-as-keys-in-hashes/48688 "2005-11-23T16:26:25Z")

</div>

I’ve seen several posts related in some way to the subject of using hashes as keys in hashes, but I haven’t seen a clear solution to the issue. My problem is I want to generate a set of unique hashes. Since hash keys…

---

## [Persistent Rinda?](https://www.ruby-forum.com/t/persistent-rinda/48674)

<div class="topic-metadata">

**Author:** [@staypufd](https://www.ruby-forum.com/u/staypufd)\
**Replies:** 1\
**Last updated:** [November 23, 2005, 4:14pm UTC](https://www.ruby-forum.com/t/persistent-rinda/48674 "2005-11-23T16:14:20Z")

</div>

I’d like to use Rinda to do some blackboard work, but I was wondering if there is a version that is persistent? I want it to be fault tolerant in that sense, so that if the process crashes or the server hangs, that t…

---

## [What is the ruby way to do this?](https://www.ruby-forum.com/t/what-is-the-ruby-way-to-do-this/48644)

<div class="topic-metadata">

**Author:** [@akonsu](https://www.ruby-forum.com/u/akonsu)\
**Replies:** 49\
**Last updated:** [November 23, 2005, 3:21pm UTC](https://www.ruby-forum.com/t/what-is-the-ruby-way-to-do-this/48644 "2005-11-23T15:21:35Z")

</div>

hello, i am still learning. in the below code @attributes is a hash table. i want to add a new value ‘a’ for a key represented by ‘a.key’. i also want to group values with the same keys in to arrays. thanks for any h…

---

## [String range membership](https://www.ruby-forum.com/t/string-range-membership/48675)

<div class="topic-metadata">

**Author:** [@warrenbrown](https://www.ruby-forum.com/u/warrenbrown)\
**Replies:** 5\
**Last updated:** [November 23, 2005, 2:04pm UTC](https://www.ruby-forum.com/t/string-range-membership/48675 "2005-11-23T14:04:41Z")

</div>

All, I ran across some code that was trying to validate that an integer was in a given range, however the integer and the range were Strings. The problem boils down to this: ruby -e “p (‘1’…‘10’).member?(‘2’)” fals…

---

## [Help embedding Ruby in Visual C++ project](https://www.ruby-forum.com/t/help-embedding-ruby-in-visual-c-project/48643)

<div class="topic-metadata">

**Author:** [@stevewong4](https://www.ruby-forum.com/u/stevewong4)\
**Replies:** 2\
**Last updated:** [November 23, 2005, 12:10pm UTC](https://www.ruby-forum.com/t/help-embedding-ruby-in-visual-c-project/48643 "2005-11-23T12:10:46Z")

</div>

Hi, I am trying to embed Ruby within a Visual C++ project, but I am having trouble loading my script file. How do I tell the Ruby interpreter where to look for my script file? If I use ruby\_options(), then my program…

---

## [Re: reverse indexing (was RE: Ruby and WMI)](https://www.ruby-forum.com/t/re-reverse-indexing-was-re-ruby-and-wmi/100633)

<div class="topic-metadata">

**Author:** [@botp](https://www.ruby-forum.com/u/botp)\
**Replies:** 0\
**Last updated:** [November 23, 2005, 10:58am UTC](https://www.ruby-forum.com/t/re-reverse-indexing-was-re-ruby-and-wmi/100633 "2005-11-23T10:58:16Z")

</div>

Sean O’Halpin \[mailto:removed\_email\_address@domain.invalid\]: #Did you know you can use reverse\_each? of course, there is even each :slight\_smile: but i am suggesting this: x=\[0,1,2,3,4,5\] =\>\[1,2,3,4,5\] x\[-1…-6\] =\>\[5…

---

## [Reverse indexing (was RE: Ruby and WMI)](https://www.ruby-forum.com/t/reverse-indexing-was-re-ruby-and-wmi/52986)

<div class="topic-metadata">

**Author:** [@botp](https://www.ruby-forum.com/u/botp)\
**Replies:** 1\
**Last updated:** [November 23, 2005, 9:36am UTC](https://www.ruby-forum.com/t/reverse-indexing-was-re-ruby-and-wmi/52986 "2005-11-23T09:36:41Z")

</div>

\#C:\\family\\ruby\>irb --simple-prompt #\>\> x=\[0,1,2,3,4,5\] #=\> \[0, 1, 2, 3, 4, 5\] … #otherwise, these will return empty arrays #\>\> x\[-1…2\] #=\> \[\] #\>\> x\[-1…-5\] #=\> \[\] #\>\> x\[-1…-4\] #=\> \[\] on the second thought,…

---

## [How to upgrade to Ruby1.8-3?](https://www.ruby-forum.com/t/how-to-upgrade-to-ruby1-8-3/49285)

<div class="topic-metadata">

**Author:** [@nospam2](https://www.ruby-forum.com/u/nospam2)\
**Replies:** 10\
**Last updated:** [November 23, 2005, 9:16am UTC](https://www.ruby-forum.com/t/how-to-upgrade-to-ruby1-8-3/49285 "2005-11-23T09:16:35Z")

</div>

Hi, I already installed Ruby 1.8-2 but I’d like to upgrade to 1.8-3 because of the security hole. Unfortunately the compilation from source fails and the only RPM that I found is not good on my distro. Is there an eas…

---

## [YAML and :SortKeys in 1.8.3](https://www.ruby-forum.com/t/yaml-and-sortkeys-in-1-8-3/48672)

<div class="topic-metadata">

**Author:** [@vjoel](https://www.ruby-forum.com/u/vjoel)\
**Replies:** 1\
**Last updated:** [November 23, 2005, 7:03am UTC](https://www.ruby-forum.com/t/yaml-and-sortkeys-in-1-8-3/48672 "2005-11-23T07:03:51Z")

</div>

What happened to this option in 1.8.3? obj.to\_yaml(:SortKeys =\> true) as in: irb(main):026:0\> hh={“6”=\>6, “11”=\>11, “7”=\>7} =\> {“11”=\>11, “6”=\>6, “7”=\>7} irb(main):027:0\> puts(hh.to\_yaml(:SortKeys =\> true)) “11”: 1…

---

## [A == nil or a.nil?](https://www.ruby-forum.com/t/a-nil-or-a-nil/99976)

<div class="topic-metadata">

**Author:** [@akonsu](https://www.ruby-forum.com/u/akonsu)\
**Replies:** 6\
**Last updated:** [November 23, 2005, 6:07am UTC](https://www.ruby-forum.com/t/a-nil-or-a-nil/99976 "2005-11-23T06:07:27Z")

</div>

hello, this is more of a philosophical question. my C experience makes me feel more comfortable with expressions such as ‘a == nil’ rather than a.nil?. i feel strange when i invoke a method on a nil value. i know, ni…

---

## [DRb Questions](https://www.ruby-forum.com/t/drb-questions/100114)

<div class="topic-metadata">

**Author:** [@james](https://www.ruby-forum.com/u/james)\
**Replies:** 3\
**Last updated:** [November 23, 2005, 4:26am UTC](https://www.ruby-forum.com/t/drb-questions/100114 "2005-11-23T04:26:54Z")

</div>

I’ve seen a couple of tutorials now claim that both sides need access to all classes used by client and server, but that’s just a half truth, right? I’m needing to build a client class that just defines an API, then …

---

## [Hiring a rubyist (SF Bay Area or remote)](https://www.ruby-forum.com/t/hiring-a-rubyist-sf-bay-area-or-remote/48663)

<div class="topic-metadata">

**Author:** [@jeff.fry](https://www.ruby-forum.com/u/jeff.fry)\
**Replies:** 0\
**Last updated:** [November 23, 2005, 3:18am UTC](https://www.ruby-forum.com/t/hiring-a-rubyist-sf-bay-area-or-remote/48663 "2005-11-23T03:18:30Z")

</div>

Hey there, I’m looking for a star coder to join our team, coding in Ruby. Depending on your experience and desire, I’d consider either a contract or a permanent position. We need someone who understands how to design …

---

## [Distributing Rails Applications (tutorial)](https://www.ruby-forum.com/t/distributing-rails-applications-tutorial/48659)

<div class="topic-metadata">

**Author:** [@pan](https://www.ruby-forum.com/u/pan)\
**Replies:** 0\
**Last updated:** [November 23, 2005, 2:26am UTC](https://www.ruby-forum.com/t/distributing-rails-applications-tutorial/48659 "2005-11-23T02:26:14Z")

</div>

I’ve updated the tutorial “Distributing Rails Applications” (with Tar2RubyScript and RubyScript2Exe) to work with Rails 0.14.3: Distributing Rails Applications - A Tutorial Please, send me reports of all bugs and gli…

---

## [What the heck (changing process uid question)](https://www.ruby-forum.com/t/what-the-heck-changing-process-uid-question/48655)

<div class="topic-metadata">

**Author:** [@joevandyk](https://www.ruby-forum.com/u/joevandyk)\
**Replies:** 3\
**Last updated:** [November 23, 2005, 2:10am UTC](https://www.ruby-forum.com/t/what-the-heck-changing-process-uid-question/48655 "2005-11-23T02:10:09Z")

</div>

My problem: When I fork a new process and set the UID of that process and want to create a log file that I redirect output into, I’m having difficulties getting the log file to be owned by the correct person. Below i…

---

## [Euchre Hands (#55)](https://www.ruby-forum.com/t/euchre-hands-55/93288)

<div class="topic-metadata">

**Author:** [@warrenbrown](https://www.ruby-forum.com/u/warrenbrown)\
**Replies:** 2\
**Last updated:** [November 23, 2005, 1:58am UTC](https://www.ruby-forum.com/t/euchre-hands-55/93288 "2005-11-23T01:58:04Z")

</div>

All, This quiz looked so simple I just couldn't resist putting in the short amount of time needed to solve it. Also, I love to play Euchre. I see other solutions trying very hard to make sure that two suits of the s…

---

## [How convert an integer to a bit array](https://www.ruby-forum.com/t/how-convert-an-integer-to-a-bit-array/48641)

<div class="topic-metadata">

**Author:** [@curt.hibbs](https://www.ruby-forum.com/u/curt.hibbs)\
**Replies:** 15\
**Last updated:** [November 23, 2005, 12:25am UTC](https://www.ruby-forum.com/t/how-convert-an-integer-to-a-bit-array/48641 "2005-11-23T00:25:24Z")

</div>

Does anyone have a clever way to convert an integer to an array of bit values? For example (using 8 bit integers): 0 =\> \[0, 0, 0, 0, 0, 0, 0, 0\] 1 =\> \[0, 0, 0, 0, 0, 0, 0, 1\] 2 =\> \[0, 0, 0, 0, 0, 0, 1, 0\] 7 =\> \[0, …

---

## [Fixrbconfig broken in 10.4.3](https://www.ruby-forum.com/t/fixrbconfig-broken-in-10-4-3/48508)

<div class="topic-metadata">

**Author:** [@rawn027](https://www.ruby-forum.com/u/rawn027)\
**Replies:** 5\
**Last updated:** [November 23, 2005, 12:01am UTC](https://www.ruby-forum.com/t/fixrbconfig-broken-in-10-4-3/48508 "2005-11-23T00:01:15Z")

</div>

I get an error saying that ruby.h cannot be found please install dev tools but i have dev tools installed and ruby.h is there when i use locate. I have no idea how to fix this, did 10.4.3 fix the problems previously t…

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

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