# Ruby

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

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

---

## [About Ruby Wx](https://www.ruby-forum.com/t/about-ruby-wx/127188)

<div class="topic-metadata">

**Author:** [@Dr.Web](https://www.ruby-forum.com/u/Dr.Web)\
**Replies:** 1\
**Last updated:** [January 26, 2008, 3:04am UTC](https://www.ruby-forum.com/t/about-ruby-wx/127188 "2008-01-26T03:04:53Z")

</div>

Hi All! I am beginner to Ruby and much interested to learn Ruby Wx, but still not able to find some useful tutorial for this topic. I have installed Ruby Wx but not able to run its any exmaple yet. I will be thankful, …

---

## [Scripts run using load in "for" loop run out of order](https://www.ruby-forum.com/t/scripts-run-using-load-in-for-loop-run-out-of-order/126959)

<div class="topic-metadata">

**Author:** [@sidd](https://www.ruby-forum.com/u/sidd)\
**Replies:** 12\
**Last updated:** [January 26, 2008, 1:07am UTC](https://www.ruby-forum.com/t/scripts-run-using-load-in-for-loop-run-out-of-order/126959 "2008-01-26T01:07:25Z")

</div>

Hi I am new to ruby and like it so far. I have an existing test harness to plug into and need to run a number of scripts in a specific order. I am using load in a “for loop” to run them. Unfortunately the scripts ge…

---

## [New classes on inheritance](https://www.ruby-forum.com/t/new-classes-on-inheritance/127191)

<div class="topic-metadata">

**Author:** [@reversejt](https://www.ruby-forum.com/u/reversejt)\
**Replies:** 1\
**Last updated:** [January 26, 2008, 12:34am UTC](https://www.ruby-forum.com/t/new-classes-on-inheritance/127191 "2008-01-26T00:34:39Z")

</div>

I’m trying to create a new globally available subclass upon the inheritance of another class. This code isn’t close to complete, but I think I’m on the right track. class PersonHelper; end class Person def self.inhe…

---

## [Re: Making Change (#154)](https://www.ruby-forum.com/t/re-making-change-154/127192)

<div class="topic-metadata">

**Author:** [@jameskelly](https://www.ruby-forum.com/u/jameskelly)\
**Replies:** 0\
**Last updated:** [January 26, 2008, 12:05am UTC](https://www.ruby-forum.com/t/re-making-change-154/127192 "2008-01-26T00:05:17Z")

</div>

make\_change(24,\[10,8,2\]) #=\> \[8,8,8\] The above may return \[10,10,2,2\] on naive solutions. ----- Original Message ---- From: Dominik H. removed\_email\_address@domain.invalid To: ruby-talk ML removed\_email\_address@doma…

---

## [Determine where a method is being called from?](https://www.ruby-forum.com/t/determine-where-a-method-is-being-called-from/126868)

<div class="topic-metadata">

**Author:** [@benjohnson](https://www.ruby-forum.com/u/benjohnson)\
**Replies:** 10\
**Last updated:** [January 25, 2008, 11:53pm UTC](https://www.ruby-forum.com/t/determine-where-a-method-is-being-called-from/126868 "2008-01-25T23:53:31Z")

</div>

Is it possible to determine if a public instance method is being called from an object or within the class? Thanks for your help.

---

## [Reg exp question](https://www.ruby-forum.com/t/reg-exp-question/127186)

<div class="topic-metadata">

**Author:** [@laredotornado](https://www.ruby-forum.com/u/laredotornado)\
**Replies:** 2\
**Last updated:** [January 25, 2008, 11:35pm UTC](https://www.ruby-forum.com/t/reg-exp-question/127186 "2008-01-25T23:35:06Z")

</div>

Hi, If I have a variable @fax, how can I apply a regular expression to the variable such that all non-numeric characters are removed? You can assume the fax number is of a valid US format. Thanks, - Dave

---

## [Anyone familiar with ArachnoRuby and the Scriptolutions site?](https://www.ruby-forum.com/t/anyone-familiar-with-arachnoruby-and-the-scriptolutions-site/127187)

<div class="topic-metadata">

**Author:** [@dkmd\_nielsen](https://www.ruby-forum.com/u/dkmd_nielsen)\
**Replies:** 0\
**Last updated:** [January 25, 2008, 11:15pm UTC](https://www.ruby-forum.com/t/anyone-familiar-with-arachnoruby-and-the-scriptolutions-site/127187 "2008-01-25T23:15:51Z")

</div>

I’m a die-hard fan of the ArachnoRuby IDE. But when I went to the Scriptolutions site to read up on the support forums, the forums are not available. Anyone know if everything is ok with the company? I have not vis…

---

## [Circular shift](https://www.ruby-forum.com/t/circular-shift/126808)

<div class="topic-metadata">

**Author:** [@z4n9ief](https://www.ruby-forum.com/u/z4n9ief)\
**Replies:** 16\
**Last updated:** [January 25, 2008, 11:04pm UTC](https://www.ruby-forum.com/t/circular-shift/126808 "2008-01-25T23:04:08Z")

</div>

Hello everybody, I would like to write a simple implementation of circular shift (Circular shift - Wikipedia). Thank you all for any ideas :slight\_smile:

---

## [Ruby 1.9 Installation Woes](https://www.ruby-forum.com/t/ruby-1-9-installation-woes/127185)

<div class="topic-metadata">

**Author:** [@fedzor](https://www.ruby-forum.com/u/fedzor)\
**Replies:** 0\
**Last updated:** [January 25, 2008, 10:32pm UTC](https://www.ruby-forum.com/t/ruby-1-9-installation-woes/127185 "2008-01-25T22:32:26Z")

</div>

I am trying to install ruby 1.9 on my mac (system details below). HOWEVER, I keep getting an ld error with ./libruby19-static.a! I understand what it’s saying but i don’t know how to fix it. Hopefully someone has run …

---

## [Too many open files (Errno::EMFILE) on Windows](https://www.ruby-forum.com/t/too-many-open-files-errno-emfile-on-windows/127176)

<div class="topic-metadata">

**Author:** [@tuq40119](https://www.ruby-forum.com/u/tuq40119)\
**Replies:** 3\
**Last updated:** [January 25, 2008, 10:32pm UTC](https://www.ruby-forum.com/t/too-many-open-files-errno-emfile-on-windows/127176 "2008-01-25T22:32:12Z")

</div>

It seems that a number of people have run into this problem in different situations. In my case, I have a large form in my Rails app with file uploads (enctype=“multipart/form-data”). When the form is submitted, the r…

---

## [Prefixes \_ and \_\_ for object and class constants proposed](https://www.ruby-forum.com/t/prefixes-and-for-object-and-class-constants-proposed/127177)

<div class="topic-metadata">

**Author:** [@Xeno\_C](https://www.ruby-forum.com/u/Xeno_C)\
**Replies:** 2\
**Last updated:** [January 25, 2008, 8:53pm UTC](https://www.ruby-forum.com/t/prefixes-and-for-object-and-class-constants-proposed/127177 "2008-01-25T20:53:50Z")

</div>

I may have brought this up before, a long time ago, but something I want is a prefix, like @ and @@, for constants that designates them as object or class constants respectively. That way I could make a lot of things …

---

## [Rubygems install in HOME for Ruby 1.9?](https://www.ruby-forum.com/t/rubygems-install-in-home-for-ruby-1-9/126904)

<div class="topic-metadata">

**Author:** [@unbewusst](https://www.ruby-forum.com/u/unbewusst)\
**Replies:** 8\
**Last updated:** [January 25, 2008, 8:52pm UTC](https://www.ruby-forum.com/t/rubygems-install-in-home-for-ruby-1-9/126904 "2008-01-25T20:52:40Z")

</div>

i’ve installed rubygems 0.9.5 with ruby 1.9 lying in my HOME but i get only a gems/1.8/ directory. then i think i didn’t use to correct version of rubygems ? is that right ? what is the best way to get rubygems worki…

---

## [Strings that contain quote marks](https://www.ruby-forum.com/t/strings-that-contain-quote-marks/127053)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 3\
**Last updated:** [January 25, 2008, 8:05pm UTC](https://www.ruby-forum.com/t/strings-that-contain-quote-marks/127053 "2008-01-25T20:05:31Z")

</div>

Sorry if this post is a duplicate, I’m having problems with my posts posting. Hello, I’ve searched through the Ruby documentation to try and figure this out - no luck at all, also searched google to see if anyone had …

---

## [Void value expression](https://www.ruby-forum.com/t/void-value-expression/127175)

<div class="topic-metadata">

**Author:** [@SASADA\_Koichi](https://www.ruby-forum.com/u/SASADA_Koichi)\
**Replies:** 0\
**Last updated:** [January 25, 2008, 7:58pm UTC](https://www.ruby-forum.com/t/void-value-expression/127175 "2008-01-25T19:58:59Z")

</div>

e$B!!$5$5$@$G$9!#e(B e$B!!0JA0!"%3%s%Q%$%i$NET9g$Ge(B redo e$B$de(B next e$B$OI,$:e(B void value e$B$K$7$F$/e(B e$B$l!"$H8@$C$F!"$=$&$7$F$b$i$C$?$h$&$J5-21$,$"$k$s$G$9$,!"$$$m$$$m$$e(B e$B$8$C$F$3$N@)8B$,\<h$l$=$&$G$9…

---

## [TextMate-like theme for NetBeans 6](https://www.ruby-forum.com/t/textmate-like-theme-for-netbeans-6/127165)

<div class="topic-metadata">

**Author:** [@Mike\_McKinney](https://www.ruby-forum.com/u/Mike_McKinney)\
**Replies:** 0\
**Last updated:** [January 25, 2008, 5:47pm UTC](https://www.ruby-forum.com/t/textmate-like-theme-for-netbeans-6/127165 "2008-01-25T17:47:22Z")

</div>

If you use TextMate and like the themes available… using NetBeans 6 without those colors can give you “eye-shock”. NB is great, try it… and avoid “eye-shock” with this theme: http://blog.huikau.com/2008/01/25/aloha-co…

---

## [What Exactly is Rubinius & Why Such Importance..?](https://www.ruby-forum.com/t/what-exactly-is-rubinius-why-such-importance/127131)

<div class="topic-metadata">

**Author:** [@softmind](https://www.ruby-forum.com/u/softmind)\
**Replies:** 7\
**Last updated:** [January 25, 2008, 5:43pm UTC](https://www.ruby-forum.com/t/what-exactly-is-rubinius-why-such-importance/127131 "2008-01-25T17:43:16Z")

</div>

Hi, I have been reading lots of headings about the New Rubinius Project and therefore decided to know more from the website. Unfortunately from the main Rubinius website and reading few blogs here and there i could n…

---

## [Ruby 1.9.0 and the debugger](https://www.ruby-forum.com/t/ruby-1-9-0-and-the-debugger/126986)

<div class="topic-metadata">

**Author:** [@jmaenpaa](https://www.ruby-forum.com/u/jmaenpaa)\
**Replies:** 3\
**Last updated:** [January 25, 2008, 4:50pm UTC](https://www.ruby-forum.com/t/ruby-1-9-0-and-the-debugger/126986 "2008-01-25T16:50:53Z")

</div>

I’ve built Ruby 1.9 and all is well with that. With respects to using the debugger, the README says “use rb\_debug”. Now does that mean require rb\_debug in an irb session or am I to recompile Ruby to include support fo…

---

## [Changing an array data structure](https://www.ruby-forum.com/t/changing-an-array-data-structure/127045)

<div class="topic-metadata">

**Author:** [@wickie](https://www.ruby-forum.com/u/wickie)\
**Replies:** 2\
**Last updated:** [January 25, 2008, 4:35pm UTC](https://www.ruby-forum.com/t/changing-an-array-data-structure/127045 "2008-01-25T16:35:33Z")

</div>

Hello. I already asked about how I’d best re-order a datastructure. But thinking about, I changed my mind; instead of the hash approach I’ve shown in news:removed\_email\_address@domain.invalid, I now think I might use…

---

## [Creating a canonicalized url](https://www.ruby-forum.com/t/creating-a-canonicalized-url/127036)

<div class="topic-metadata">

**Author:** [@thechak](https://www.ruby-forum.com/u/thechak)\
**Replies:** 9\
**Last updated:** [January 25, 2008, 4:27pm UTC](https://www.ruby-forum.com/t/creating-a-canonicalized-url/127036 "2008-01-25T16:27:20Z")

</div>

Hello there guys, I’m trying to track down an easy way to canonicalize a URL from with ruby. I’ve been looking around for this but all I can find are some procedure hacks sure as # canonicalize the url if ($url -not…

---

## [Range patch](https://www.ruby-forum.com/t/range-patch/127153)

<div class="topic-metadata">

**Author:** [@editkid](https://www.ruby-forum.com/u/editkid)\
**Replies:** 1\
**Last updated:** [January 25, 2008, 4:17pm UTC](https://www.ruby-forum.com/t/range-patch/127153 "2008-01-25T16:17:12Z")

</div>

Sorry, I introduced a small bug since I didn’t check all the other specs were still working (tut tut). The String#upto spec picked up a quirk of MRI that I broke in rbx: This is weird but MRI behaves like that it “u…

---

## [Regexp#source$B$N(Bencoding](https://www.ruby-forum.com/t/regexp-source-b-n-bencoding/127152)

<div class="topic-metadata">

**Author:** [@Kazuhiro\_NISHIYAMA](https://www.ruby-forum.com/u/Kazuhiro_NISHIYAMA)\
**Replies:** 0\
**Last updated:** [January 25, 2008, 3:00pm UTC](https://www.ruby-forum.com/t/regexp-source-b-n-bencoding/127152 "2008-01-25T15:00:16Z")

</div>

e$B@\>;3OB9-$G$9!#e(B Regexp#sourcee$B$Ne(Bencodinge$B$,e(BRegexp#encodinge$B$K4X78$J$/e(B ASCII-8BITe$B$K$J$C$F$$$k$h$&$J5$$,$7$^$9!#e(B % cat e.rb -- coding: utf-8 -- re = /e$B$"e(B/ p re.encoding p re.source.enco…

---

## [Regex issue](https://www.ruby-forum.com/t/regex-issue/127150)

<div class="topic-metadata">

**Author:** [@Junkone](https://www.ruby-forum.com/u/Junkone)\
**Replies:** 3\
**Last updated:** [January 25, 2008, 2:48pm UTC](https://www.ruby-forum.com/t/regex-issue/127150 "2008-01-25T14:48:39Z")

</div>

my pattern should match either import or delete However it does not seem to be working. irb(main):014:0\> pattern="(\[import\]|\[delete\])" =\> “(\[import\]|\[delete\])” irb(main):015:0\> pattern.match(“import”) =\> #MatchData:…

---

## [Composition/inheritance/subclassing standard lib classes](https://www.ruby-forum.com/t/composition-inheritance-subclassing-standard-lib-classes/122935)

<div class="topic-metadata">

**Author:** [@bobt](https://www.ruby-forum.com/u/bobt)\
**Replies:** 3\
**Last updated:** [January 25, 2008, 1:30pm UTC](https://www.ruby-forum.com/t/composition-inheritance-subclassing-standard-lib-classes/122935 "2008-01-25T13:30:54Z")

</div>

Hi, An old ruby quiz (#24) deals with a game of poker, and there’s a “Deck” class in a couple of solutions. These classes have an array of Card objects. Similarly, in an example in the Prag porgrammers guide, a SongL…

---

## [What this code means?](https://www.ruby-forum.com/t/what-this-code-means/127141)

<div class="topic-metadata">

**Author:** [@MohsinHijazee](https://www.ruby-forum.com/u/MohsinHijazee)\
**Replies:** 1\
**Last updated:** [January 25, 2008, 12:43pm UTC](https://www.ruby-forum.com/t/what-this-code-means/127141 "2008-01-25T12:43:48Z")

</div>

Hello! I am new to Ruby, can anyone explain what this code snippet is trying to do? module YourLastModule class \<\< self def included© class \<\< c def say\_hellol(name) return "Hello, " + name end end end end e…

---

## [Next Generation Web](https://www.ruby-forum.com/t/next-generation-web/127139)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [January 25, 2008, 11:40am UTC](https://www.ruby-forum.com/t/next-generation-web/127139 "2008-01-25T11:40:54Z")

</div>

AJ Square’s Next-Generation web solution is expressly designed to help organizations meet these expectations. An integrated suite built on AJ Square Portal Services integrated with the Next-Generation web solution inc…

---

## [Using a DLL that wants a function pointer](https://www.ruby-forum.com/t/using-a-dll-that-wants-a-function-pointer/127046)

<div class="topic-metadata">

**Author:** [@daniel\_SSSSkerud](https://www.ruby-forum.com/u/daniel_SSSSkerud)\
**Replies:** 7\
**Last updated:** [January 25, 2008, 10:29am UTC](https://www.ruby-forum.com/t/using-a-dll-that-wants-a-function-pointer/127046 "2008-01-25T10:29:34Z")

</div>

I want to use a DLL with Ruby (Win32). This DLL has X number of functions, and one of these takes a function pointer. The DLL will call this callback-function when some data arrives. I cannot figure out how to do thi…

---

## ["Parametric class" on inheritance](https://www.ruby-forum.com/t/parametric-class-on-inheritance/127062)

<div class="topic-metadata">

**Author:** [@ronaldfischer](https://www.ruby-forum.com/u/ronaldfischer)\
**Replies:** 3\
**Last updated:** [January 25, 2008, 8:54am UTC](https://www.ruby-forum.com/t/parametric-class-on-inheritance/127062 "2008-01-25T08:54:24Z")

</div>

I found in “Ruby Cookbook” (recipe 8.8) a syntactically interesting construct, which I would like to understand. Here is the excerpt from the coding example: require ‘delegate’ class OrdinalNumber \< DelegateClass(Fix…

---

## [Getting in lots of practice at begginner level](https://www.ruby-forum.com/t/getting-in-lots-of-practice-at-begginner-level/127104)

<div class="topic-metadata">

**Author:** [@scudco](https://www.ruby-forum.com/u/scudco)\
**Replies:** 4\
**Last updated:** [January 25, 2008, 8:15am UTC](https://www.ruby-forum.com/t/getting-in-lots-of-practice-at-begginner-level/127104 "2008-01-25T08:15:18Z")

</div>

hi just getting to grips with ruby. I need more problems to solve that are fairly targeted on a particular area of ruby, perhaps short as well. E.g stuff with strings and their methods, or handling 2d arrays, file inp…

---

## [Printf "%#o\\n", -1](https://www.ruby-forum.com/t/printf-o-n-1/127121)

<div class="topic-metadata">

**Author:** [@Tanaka\_A](https://www.ruby-forum.com/u/Tanaka_A)\
**Replies:** 0\
**Last updated:** [January 25, 2008, 4:41am UTC](https://www.ruby-forum.com/t/printf-o-n-1/127121 "2008-01-25T04:41:20Z")

</div>

e$B0J2\<$N$h$&$Ke(B printf e$B$Ge(B %#o e$B$Ke(B -1 e$B$rM?$($k$He(B 0…7 e$B$K$J$j$^$9!#e(B % ./ruby -ve ‘printf “%#o\\n”, -1’ ruby 1.9.0 (2008-01-24 revision 0) \[i686-linux\] 0…7 8e$B?J?t$Ge(B -1 e$B$re(B 8e$B$NJd?t$H…

---

## [Looking for code to determine length of audio files](https://www.ruby-forum.com/t/looking-for-code-to-determine-length-of-audio-files/126530)

<div class="topic-metadata">

**Author:** [@rykkers](https://www.ruby-forum.com/u/rykkers)\
**Replies:** 10\
**Last updated:** [January 25, 2008, 2:50am UTC](https://www.ruby-forum.com/t/looking-for-code-to-determine-length-of-audio-files/126530 "2008-01-25T02:50:44Z")

</div>

I’m working on a project which has the requirement to automatically determine the runtime of audio files in several formats, right now mp3 and aac. I googled around to see if there might be some existing code, hopefu…

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

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