# Ruby

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

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

---

## [K&R for Ruby?](https://www.ruby-forum.com/t/k-r-for-ruby/71118)

<div class="topic-metadata">

**Author:** [@Esmail\_B](https://www.ruby-forum.com/u/Esmail_B)\
**Replies:** 9\
**Last updated:** [October 6, 2006, 8:27pm UTC](https://www.ruby-forum.com/t/k-r-for-ruby/71118 "2006-10-06T20:27:22Z")

</div>

Hello, Is there a concise introduction/coverage of Ruby similar to how Kernighan & Ritchie did for C? I am quite comfortable with programming, and I am currently reading “Programming Ruby” which I like, but it seems …

---

## [Re: Posix Pangrams (#97)](https://www.ruby-forum.com/t/re-posix-pangrams-97/71288)

<div class="topic-metadata">

**Author:** [@phrogz](https://www.ruby-forum.com/u/phrogz)\
**Replies:** 2\
**Last updated:** [October 6, 2006, 8:21pm UTC](https://www.ruby-forum.com/t/re-posix-pangrams-97/71288 "2006-10-06T20:21:20Z")

</div>

This quiz extends the idea to the posix utilities\[1\] \[snip\] \[1\] http://www.unix.org/version3/apis/cu.html has a complete list Assuming it’s not a spoiler, following is the contents of the first column of the table …

---

## [Re: Posix Pangrams (#97)](https://www.ruby-forum.com/t/re-posix-pangrams-97/71298)

<div class="topic-metadata">

**Author:** [@phrogz](https://www.ruby-forum.com/u/phrogz)\
**Replies:** 2\
**Last updated:** [October 6, 2006, 7:47pm UTC](https://www.ruby-forum.com/t/re-posix-pangrams-97/71298 "2006-10-06T19:47:12Z")

</div>

From: Jamie M. \[mailto:removed\_email\_address@domain.invalid\] (There’s no joy in trying to parse/string HTML.) Sure there is. require ‘rubygems’; require ‘hpricot’; require ‘open-uri’ doc = Hpricot(open(‘http://www…

---

## [Re: Posix Pangrams (#97)](https://www.ruby-forum.com/t/re-posix-pangrams-97/71304)

<div class="topic-metadata">

**Author:** [@phrogz](https://www.ruby-forum.com/u/phrogz)\
**Replies:** 0\
**Last updated:** [October 6, 2006, 7:39pm UTC](https://www.ruby-forum.com/t/re-posix-pangrams-97/71304 "2006-10-06T19:39:11Z")

</div>

puts (doc/“p.tent/i”).map{|i|i.inner\_html} Actually…I can’t get Hpricot to install to test your code (gem server seems to be down) but doesn’t that grab way more information than you wanted from the table? The tabl…

---

## [Parse and modify an XML file with REXML](https://www.ruby-forum.com/t/parse-and-modify-an-xml-file-with-rexml/71171)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 7\
**Last updated:** [October 6, 2006, 7:12pm UTC](https://www.ruby-forum.com/t/parse-and-modify-an-xml-file-with-rexml/71171 "2006-10-06T19:12:45Z")

</div>

Greetings all. When processing XML, is there a way to check what the previous and what the next “rows” are? That probably makes no sense without context, so here is an example. I need to find things in the XML based …

---

## [Setting up simple CGI on Ubuntu](https://www.ruby-forum.com/t/setting-up-simple-cgi-on-ubuntu/71183)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 6\
**Last updated:** [October 6, 2006, 6:46pm UTC](https://www.ruby-forum.com/t/setting-up-simple-cgi-on-ubuntu/71183 "2006-10-06T18:46:41Z")

</div>

I’ve done all this numerous times before but, sigh, apparently I’m forgetting something. I’m just trying to serve up a straight CGI script, nothing fancy. Running Ubuntu Apache2: \<VirtualHost \*\> #SetEnv RAILS\_ENV de…

---

## [Getstatusoutput](https://www.ruby-forum.com/t/getstatusoutput/71261)

<div class="topic-metadata">

**Author:** [@OliverMarchand](https://www.ruby-forum.com/u/OliverMarchand)\
**Replies:** 3\
**Last updated:** [October 6, 2006, 6:40pm UTC](https://www.ruby-forum.com/t/getstatusoutput/71261 "2006-10-06T18:40:39Z")

</div>

Dear Ruby fellows, I am desperately trying to write a quite simple function (something similar to what I was acumstomed to with Python) status, stdout, stderr = getstatusoutput(somecmdstring) status is an integer, st…

---

## [Getstatusoutput](https://www.ruby-forum.com/t/getstatusoutput/102864)

<div class="topic-metadata">

**Author:** [@OliverMarchand](https://www.ruby-forum.com/u/OliverMarchand)\
**Replies:** 0\
**Last updated:** [October 6, 2006, 6:16pm UTC](https://www.ruby-forum.com/t/getstatusoutput/102864 "2006-10-06T18:16:36Z")

</div>

Dear Ruby fellows, I am desperately trying to write a quite simple function (something similar to what I was acumstomed to with Python) status, stdout, stderr = getstatusoutput(somecmdstring) status is an integer, st…

---

## [BFTS (was Re: RubySpec Wiki in full swing)](https://www.ruby-forum.com/t/bfts-was-re-rubyspec-wiki-in-full-swing/71285)

<div class="topic-metadata">

**Author:** [@MSEdward\_SEdS\_Bora](https://www.ruby-forum.com/u/MSEdward_SEdS_Bora)\
**Replies:** 0\
**Last updated:** [October 6, 2006, 5:52pm UTC](https://www.ruby-forum.com/t/bfts-was-re-rubyspec-wiki-in-full-swing/71285 "2006-10-06T17:52:32Z")

</div>

Brian M. wrote: That has been forked off into oblivion it seems. Ryan D. started the BFTS project not long after RubyConf05 but it is only available in a perforce repository last I heard. I am still interested in wor…

---

## [Some wierd Module#append\_features behavior](https://www.ruby-forum.com/t/some-wierd-module-append-features-behavior/71199)

<div class="topic-metadata">

**Author:** [@bdmcnitt](https://www.ruby-forum.com/u/bdmcnitt)\
**Replies:** 4\
**Last updated:** [October 6, 2006, 5:34pm UTC](https://www.ruby-forum.com/t/some-wierd-module-append-features-behavior/71199 "2006-10-06T17:34:27Z")

</div>

I couldn’t quite figure this out… I am either missing something (I hope) or there is a small bug: Module === Module #=\> true Module === Module.new #=\> true af = Module.instance\_method(:append\_features) af.bind(Modul…

---

## [Should a Class return an exception or nil on failure to crea](https://www.ruby-forum.com/t/should-a-class-return-an-exception-or-nil-on-failure-to-crea/71253)

<div class="topic-metadata">

**Author:** [@S\_Kevin](https://www.ruby-forum.com/u/S_Kevin)\
**Replies:** 3\
**Last updated:** [October 6, 2006, 4:52pm UTC](https://www.ruby-forum.com/t/should-a-class-return-an-exception-or-nil-on-failure-to-crea/71253 "2006-10-06T16:52:16Z")

</div>

Suppose I’ve written a class that does something useful. This class, let’s call it a Widget, is created like this… a = Widget.new(some\_value) Not all values of ‘some\_value’ are valid and I need to indicate when creat…

---

## [Getstatusoutput](https://www.ruby-forum.com/t/getstatusoutput/102547)

<div class="topic-metadata">

**Author:** [@OliverMarchand](https://www.ruby-forum.com/u/OliverMarchand)\
**Replies:** 0\
**Last updated:** [October 6, 2006, 3:07pm UTC](https://www.ruby-forum.com/t/getstatusoutput/102547 "2006-10-06T15:07:48Z")

</div>

Dear Ruby fellows, I am desperately trying to write a quite simple function (something similar to what I was acumstomed to with Python) status, stdout, stderr = getstatusoutput(somecmdstring) status is an integer, st…

---

## [Script arg with doble quote](https://www.ruby-forum.com/t/script-arg-with-doble-quote/71149)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 6\
**Last updated:** [October 6, 2006, 1:51pm UTC](https://www.ruby-forum.com/t/script-arg-with-doble-quote/71149 "2006-10-06T13:51:14Z")

</div>

when i have a path like that : /path/to/“Hello\\ world”/ this string being the argument of a ruby script (the same does apply for shell scripts) i don’t get it right but rather : /path/to/Hello world/ the doble quote…

---

## [System() and changing (path-)environment](https://www.ruby-forum.com/t/system-and-changing-path-environment/71233)

<div class="topic-metadata">

**Author:** [@Karl\_V](https://www.ruby-forum.com/u/Karl_V)\
**Replies:** 1\
**Last updated:** [October 6, 2006, 1:43pm UTC](https://www.ruby-forum.com/t/system-and-changing-path-environment/71233 "2006-10-06T13:43:13Z")

</div>

Hi! I want to replace some shellscripts using ruby and therefore I need a method to execute external scripts (ksh). Without rewriting a lot of scripts, I need the possibility to execute external scripts in another di…

---

## [String size limit?](https://www.ruby-forum.com/t/string-size-limit/71245)

<div class="topic-metadata">

**Author:** [@randw](https://www.ruby-forum.com/u/randw)\
**Replies:** 1\
**Last updated:** [October 6, 2006, 1:37pm UTC](https://www.ruby-forum.com/t/string-size-limit/71245 "2006-10-06T13:37:11Z")

</div>

Does Ruby impose a limit on the size of a string? What about the size of an array? Thanks in advance. Rand

---

## [Parsing files](https://www.ruby-forum.com/t/parsing-files/71215)

<div class="topic-metadata">

**Author:** [@barjunk](https://www.ruby-forum.com/u/barjunk)\
**Replies:** 2\
**Last updated:** [October 6, 2006, 9:40am UTC](https://www.ruby-forum.com/t/parsing-files/71215 "2006-10-06T09:40:48Z")

</div>

I’m new to ruby and one of the first projects I am trying to tackle is parsing a file with this sort of format: zone “localdomain” IN { type master; file “localdomain.zone”; allow-update { none; }; }; or host dev…

---

## [Dynamically changing superclass/mixins](https://www.ruby-forum.com/t/dynamically-changing-superclass-mixins/70837)

<div class="topic-metadata">

**Author:** [@mrkohrea](https://www.ruby-forum.com/u/mrkohrea)\
**Replies:** 17\
**Last updated:** [October 6, 2006, 9:20am UTC](https://www.ruby-forum.com/t/dynamically-changing-superclass-mixins/70837 "2006-10-06T09:20:46Z")

</div>

I have strong interest in highly dynamic languages, particularly prototype-based languages - and am still looking for the language that I have to “abuse least” to achieve what I want (for my attempt in Java, see http:…

---

## [Extract relative links from html page](https://www.ruby-forum.com/t/extract-relative-links-from-html-page/71223)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 1\
**Last updated:** [October 6, 2006, 7:46am UTC](https://www.ruby-forum.com/t/extract-relative-links-from-html-page/71223 "2006-10-06T07:46:40Z")

</div>

Does somebody have any suggestions on how to extract relative as well as absolute links from an html page. It seems like the URI.extract only matches on absolute urls. Any pointers or suggestions are appreciated. THa…

---

## [Append\_features vs include](https://www.ruby-forum.com/t/append-features-vs-include/71207)

<div class="topic-metadata">

**Author:** [@rsanheim](https://www.ruby-forum.com/u/rsanheim)\
**Replies:** 3\
**Last updated:** [October 6, 2006, 6:46am UTC](https://www.ruby-forum.com/t/append-features-vs-include/71207 "2006-10-06T06:46:37Z")

</div>

I’ve read somewhere that Module#append\_features is the old name for this method, and “included” should be used going forward. Makes sense to me, as “included” is shorter and fits the method better, anyways. So is “ap…

---

## [Associating data with a function](https://www.ruby-forum.com/t/associating-data-with-a-function/71058)

<div class="topic-metadata">

**Author:** [@phrogz](https://www.ruby-forum.com/u/phrogz)\
**Replies:** 17\
**Last updated:** [October 6, 2006, 6:02am UTC](https://www.ruby-forum.com/t/associating-data-with-a-function/71058 "2006-10-06T06:02:34Z")

</div>

Because I just had to solve this problem in both JavaScript and Lua, and because I love Ruby more than either, I thought I’d ask people here how they’d solve it in Ruby. The general question is: how would do you assoc…

---

## [RubySpec Wiki in full swing](https://www.ruby-forum.com/t/rubyspec-wiki-in-full-swing/71221)

<div class="topic-metadata">

**Author:** [@headius](https://www.ruby-forum.com/u/headius)\
**Replies:** 0\
**Last updated:** [October 6, 2006, 5:06am UTC](https://www.ruby-forum.com/t/rubyspec-wiki-in-full-swing/71221 "2006-10-06T05:06:33Z")

</div>

To help us alternative Ruby implementers keep our sanity, I’ve had a wiki up for several weeks to see if it would work for gathering documentation and information on the Ruby language, libraries, runtime, and implemen…

---

## [\[ ruby-Patches-6026 \] net/imap chokes on NOMODSEQ response](https://www.ruby-forum.com/t/ruby-patches-6026-net-imap-chokes-on-nomodseq-response/71092)

<div class="topic-metadata">

**Author:** [@Yukihiro\_M](https://www.ruby-forum.com/u/Yukihiro_M)\
**Replies:** 1\
**Last updated:** [October 6, 2006, 2:40am UTC](https://www.ruby-forum.com/t/ruby-patches-6026-net-imap-chokes-on-nomodseq-response/71092 "2006-10-06T02:40:11Z")

</div>

e$B$^$D$b$He(B e$B$f$-$R$m$G$9e(B e$BE\>Aw$G$9!#e(B\[ruby-core:09002\]e$B$N%Q%C%A$K$D$$$F3NG’$7$F$b$i$($^e(B e$B$;$s$G$7$g$&$+e(B e$B!de(B e$B\<g$KA0ED$5$se(B http://rubyforge.org/tracker/?func=detail&atid=1700&aid=6026&g…

---

## [Installing Ruby from source on OSX](https://www.ruby-forum.com/t/installing-ruby-from-source-on-osx/71201)

<div class="topic-metadata">

**Author:** [@dfg59](https://www.ruby-forum.com/u/dfg59)\
**Replies:** 4\
**Last updated:** [October 6, 2006, 2:34am UTC](https://www.ruby-forum.com/t/installing-ruby-from-source-on-osx/71201 "2006-10-06T02:34:10Z")

</div>

I’ve become a die-hard Ruby fan in the past few months. I’m currently using 1.8.5 on my work PC and want to upgrade on my mac at home, which is currently running 1.8.2. It seems the neither Fink nor Darwinports has 1.…

---

## [1st program -- how would you improve this?](https://www.ruby-forum.com/t/1st-program-how-would-you-improve-this/71182)

<div class="topic-metadata">

**Author:** [@Esmail\_B](https://www.ruby-forum.com/u/Esmail_B)\
**Replies:** 9\
**Last updated:** [October 6, 2006, 2:06am UTC](https://www.ruby-forum.com/t/1st-program-how-would-you-improve-this/71182 "2006-10-06T02:06:08Z")

</div>

Hi, I just wrote my first Ruby program and I would be very interested in some feedback as to style and how to write things more in the Ruby-way. I know I could use more methods and/or possibly classes, and that will…

---

## [Re: Installing Ruby from source on OSX](https://www.ruby-forum.com/t/re-installing-ruby-from-source-on-osx/71202)

<div class="topic-metadata">

**Author:** [@phrogz](https://www.ruby-forum.com/u/phrogz)\
**Replies:** 0\
**Last updated:** [October 6, 2006, 1:38am UTC](https://www.ruby-forum.com/t/re-installing-ruby-from-source-on-osx/71202 "2006-10-06T01:38:06Z")

</div>

From: Drew O. I’ve become a die-hard Ruby fan in the past few months. I’m currently using 1.8.5 on my work PC and want to upgrade on my mac at home, which is currently running 1.8.2. It seems the neither Fink nor Da…

---

## ["Succinctness is Power", by Paul Graham](https://www.ruby-forum.com/t/succinctness-is-power-by-paul-graham/70384)

<div class="topic-metadata">

**Author:** [@iceburgh](https://www.ruby-forum.com/u/iceburgh)\
**Replies:** 47\
**Last updated:** [October 6, 2006, 1:24am UTC](https://www.ruby-forum.com/t/succinctness-is-power-by-paul-graham/70384 "2006-10-06T01:24:04Z")

</div>

This is probably old news to many here, but I found it to be an interesting read, with implications for Ruby. “Succinctness is Power” Paul Graham -r http://www.cfcl.com/rdm Rich M. http://www.cfcl.com/rd…

---

## [Re: HOST - Assembla Inc. Breakout - Copyright Violation by M](https://www.ruby-forum.com/t/re-host-assembla-inc-breakout-copyright-violation-by-m/71200)

<div class="topic-metadata">

**Author:** [@Gennady\_B](https://www.ruby-forum.com/u/Gennady_B)\
**Replies:** 0\
**Last updated:** [October 6, 2006, 1:12am UTC](https://www.ruby-forum.com/t/re-host-assembla-inc-breakout-copyright-violation-by-m/71200 "2006-10-06T01:12:03Z")

</div>

Erik Max Francis wrote: Ilias L. wrote: please relax and do not speak for all current and future readers (archives). He may not be speaking for all of them, but he’s speaking for the vast majority. You are a con…

---

## [Re: HOST - Assembla Inc. Breakout - Copyright Violation by M](https://www.ruby-forum.com/t/re-host-assembla-inc-breakout-copyright-violation-by-m/71189)

<div class="topic-metadata">

**Author:** [@Ilias\_L](https://www.ruby-forum.com/u/Ilias_L)\
**Replies:** 5\
**Last updated:** [October 6, 2006, 1:02am UTC](https://www.ruby-forum.com/t/re-host-assembla-inc-breakout-copyright-violation-by-m/71189 "2006-10-06T01:02:03Z")

</div>

\[For some reason, the newsgroup server seems to not have distributed the messages yet. Thus posting via groups-google now. first message was from 2006-09-27, second message from 2006-09-28, both with a CC to Andy Sing…

---

## [Why can't Ruby automatically cast variables?](https://www.ruby-forum.com/t/why-cant-ruby-automatically-cast-variables/70613)

<div class="topic-metadata">

**Author:** [@joe](https://www.ruby-forum.com/u/joe)\
**Replies:** 8\
**Last updated:** [October 6, 2006, 12:50am UTC](https://www.ruby-forum.com/t/why-cant-ruby-automatically-cast-variables/70613 "2006-10-06T00:50:02Z")

</div>

One thing that annoys me about Ruby is that casting variables is required: i = 5 a = ‘logan’ puts a + i.to\_s Or a=‘2’ b=3 puts a.to\_i + b Why can’t (or can?) Ruby just handle ‘puts a + i’ or ‘puts a+b’? Joe

---

## [Module.new](https://www.ruby-forum.com/t/module-new/71105)

<div class="topic-metadata">

**Author:** [@WATANABE\_Hirofumi](https://www.ruby-forum.com/u/WATANABE_Hirofumi)\
**Replies:** 4\
**Last updated:** [October 6, 2006, 12:36am UTC](https://www.ruby-forum.com/t/module-new/71105 "2006-10-06T00:36:01Z")

</div>

e$B$o$?$J$Y$G$9!#e(B 1.9e$B$Ne(BModule.newe$B$N%V%m%C%/0z?t$,$J$\<$+e(Bnile$B$K$J$C$F$7$^$$$^$9!#e(B % ruby-1.9 -e ‘Module.new{|mod| p mod}’ nil e$B$=$l$O$=$l$H$7$F!"e(Bmake minirubye$B$@$1$G$J$/\>/$J$/$H$be(Bmakee$B$…

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

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