# Ruby

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

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

---

## [Re: Completely uninstalling one-click installer](https://www.ruby-forum.com/t/re-completely-uninstalling-one-click-installer/59463)

<div class="topic-metadata">

**Author:** [@jamal86](https://www.ruby-forum.com/u/jamal86)\
**Replies:** 2\
**Last updated:** [May 3, 2006, 7:07pm UTC](https://www.ruby-forum.com/t/re-completely-uninstalling-one-click-installer/59463 "2006-05-03T19:07:28Z")

</div>

I have found that the One Click Installer sets an environmental variable called RUBYOPT that points to the Ruby Gems library. This causes a problem if a copy of the Ruby interpreter is run on the same computer from a…

---

## [Problem with SQLite and Ruby](https://www.ruby-forum.com/t/problem-with-sqlite-and-ruby/59450)

<div class="topic-metadata">

**Author:** [@tekhne](https://www.ruby-forum.com/u/tekhne)\
**Replies:** 4\
**Last updated:** [May 3, 2006, 7:07pm UTC](https://www.ruby-forum.com/t/problem-with-sqlite-and-ruby/59450 "2006-05-03T19:07:28Z")

</div>

I’m having a little problem here. I have a version 2 SQLite database and the following code: #!/usr/bin/ruby require ‘sqlite’ db = SQLite::Database.new( “db/ars.db”, 0644 ) db.results\_as\_hash = true db.execute( “SE…

---

## [Re: Ruby number crunching?](https://www.ruby-forum.com/t/re-ruby-number-crunching/59462)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [May 3, 2006, 7:07pm UTC](https://www.ruby-forum.com/t/re-ruby-number-crunching/59462 "2006-05-03T19:07:17Z")

</div>

Dear Alex, there is a fairly complete numerical library called GSL (Gnu Scientific Library). And there are bindings for it in Ruby (rb-gsl I think, just type in Ruby and GSL at Google :). Best regards, Axel

---

## [Array.include? strangeness](https://www.ruby-forum.com/t/array-include-strangeness/59290)

<div class="topic-metadata">

**Author:** [@Martin\_Smith](https://www.ruby-forum.com/u/Martin_Smith)\
**Replies:** 4\
**Last updated:** [May 3, 2006, 7:07pm UTC](https://www.ruby-forum.com/t/array-include-strangeness/59290 "2006-05-03T19:07:16Z")

</div>

Array.include? doesn’t seem to be telling me the truth. Obviously this is ME getting it wrong, but could somebody explain what is happening please. First I set up ab array of common words def initialize @common\_wor…

---

## [Re: Problem with MODULO function?](https://www.ruby-forum.com/t/re-problem-with-modulo-function/59454)

<div class="topic-metadata">

**Author:** [@jan\_aerts\_SRI](https://www.ruby-forum.com/u/jan_aerts_SRI)\
**Replies:** 1\
**Last updated:** [May 3, 2006, 7:07pm UTC](https://www.ruby-forum.com/t/re-problem-with-modulo-function/59454 "2006-05-03T19:07:11Z")

</div>

Hi Peter, I think it has to do with the fact that numberofpages is a string instead of an integer. In the irb: number\_of\_pages = 5 number\_of\_pages % 2 =\> 1 number\_of\_pages = ‘5’ number\_of\_pages % 2 =\> 5 S…

---

## [Completely uninstalling one-click installer](https://www.ruby-forum.com/t/completely-uninstalling-one-click-installer/59449)

<div class="topic-metadata">

**Author:** [@victor123789](https://www.ruby-forum.com/u/victor123789)\
**Replies:** 1\
**Last updated:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/completely-uninstalling-one-click-installer/59449 "2006-05-03T19:06:57Z")

</div>

Hi all. Here is the situation: a few monthes ago I’ve started my excersises with Ruby. I’ve downloaded One-Cilck Installer, installed it and was happy. I’ve installed also rubygems, rdoc, some third-party libraries, …

---

## [Installing 'win32-service-0.5.0' gives errors?](https://www.ruby-forum.com/t/installing-win32-service-0-5-0-gives-errors/94380)

<div class="topic-metadata">

**Author:** [@udinesh](https://www.ruby-forum.com/u/udinesh)\
**Replies:** 1\
**Last updated:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/installing-win32-service-0-5-0-gives-errors/94380 "2006-05-03T19:06:56Z")

</div>

Hi all, I’m trying to install the package “win32-service-0.5.0” on my system - XP. I’m getting the below errors I Have downloaded the “win32-service-0.5.0” package and as per the readme i have to first execute the be…

---

## [Cookies and SSI](https://www.ruby-forum.com/t/cookies-and-ssi/59448)

<div class="topic-metadata">

**Author:** [@Rene\_T](https://www.ruby-forum.com/u/Rene_T)\
**Replies:** 0\
**Last updated:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/cookies-and-ssi/59448 "2006-05-03T19:06:56Z")

</div>

Dear Ruby Experts, I am somewhat confused about that CGI stuff. I have successfully written a Ruby script that sets a cookie. The script is called directly as CGI script, because I noticed that it seems to be impossib…

---

## [Calling Shell Scripts from Ruby?](https://www.ruby-forum.com/t/calling-shell-scripts-from-ruby/59249)

<div class="topic-metadata">

**Author:** [@udinesh](https://www.ruby-forum.com/u/udinesh)\
**Replies:** 13\
**Last updated:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/calling-shell-scripts-from-ruby/59249 "2006-05-03T19:06:51Z")

</div>

Hi all, I have two questions 1)Is it possible to call “Shell Scripts” from ruby? Say if i have a shell sciprt named “test.sh”, how can i call this from ruby? Also if i can call like that,is it possible to get the out…

---

## [Dave Thomas' ego thread](https://www.ruby-forum.com/t/dave-thomas-ego-thread/59442)

<div class="topic-metadata">

**Author:** [@daz](https://www.ruby-forum.com/u/daz)\
**Replies:** 0\
**Last updated:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/dave-thomas-ego-thread/59442 "2006-05-03T19:06:49Z")

</div>

Here’s a Quote of the Week in lieu of Ruby Weekly News. Jeff D. wrote in \[ruby-talk:191063\]: If you use Ruby and you use English, you’re not allowed to get upset at Dave T… That’s all there is to it :wink: Jeff’s …

---

## [RubyKaigi 2006](https://www.ruby-forum.com/t/rubykaigi-2006/94423)

<div class="topic-metadata">

**Author:** [@SASADA\_Koichi](https://www.ruby-forum.com/u/SASADA_Koichi)\
**Replies:** 0\
**Last updated:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/rubykaigi-2006/94423 "2006-05-03T19:06:27Z")

</div>

Hi, We will hold Japan Ruby Conference 2006 a.k.a RubyKaigi 2006 in Odaiba, Tokyo, Japan at 10-11, Jun 2006. http://jp.rubyist.net/RubyKaigi2006/ This conference is a forthcoming event that gathers a lot of branc…

---

## [Python and Ruby interpretability](https://www.ruby-forum.com/t/python-and-ruby-interpretability/59277)

<div class="topic-metadata">

**Author:** [@alan](https://www.ruby-forum.com/u/alan)\
**Replies:** 1\
**Last updated:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/python-and-ruby-interpretability/59277 "2006-05-03T19:06:27Z")

</div>

Hi, Can I use this Python tool/library in my Ruby application? http://pyclips.sourceforge.net/ Thank you, Alan

---

## [Cat2rafb (#77)](https://www.ruby-forum.com/t/cat2rafb-77/94319)

<div class="topic-metadata">

**Author:** [@bbazzarrakk](https://www.ruby-forum.com/u/bbazzarrakk)\
**Replies:** 8\
**Last updated:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/cat2rafb-77/94319 "2006-05-03T19:06:20Z")

</div>

The three rules of Ruby Q.: Please do not post any solutions or spoiler discussion for this quiz until 48 hours have passed from the time on this message. Support Ruby Q. by submitting ideas as often as you can: …

---

## [System() vs. commandline?](https://www.ruby-forum.com/t/system-vs-commandline/59274)

<div class="topic-metadata">

**Author:** [@joe](https://www.ruby-forum.com/u/joe)\
**Replies:** 3\
**Last updated:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/system-vs-commandline/59274 "2006-05-03T19:06:19Z")

</div>

I have a C program that processes text files. When I run it from the commandline, it works fine. But if I run it via Ruby with ‘system(“textproc input output”)’ that output file usually gets truncated near its end. Th…

---

## [Unpack \*.gem](https://www.ruby-forum.com/t/unpack-gem/94422)

<div class="topic-metadata">

**Author:** [@victor123789](https://www.ruby-forum.com/u/victor123789)\
**Replies:** 2\
**Last updated:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/unpack-gem/94422 "2006-05-03T19:06:19Z")

</div>

Hi all. Some good and interesting library at rubyforge can be downloaded only as \*.gem The question is: is there method for unpack library and view its source and docs without installing it? I need such functionali…

---

## [Syntax highlighting library](https://www.ruby-forum.com/t/syntax-highlighting-library/94408)

<div class="topic-metadata">

**Author:** [@victor123789](https://www.ruby-forum.com/u/victor123789)\
**Replies:** 3\
**Last updated:** [May 3, 2006, 7:06pm UTC](https://www.ruby-forum.com/t/syntax-highlighting-library/94408 "2006-05-03T19:06:10Z")

</div>

Hello all. Does some good subj exists? If no, maybe it would be useful If I’ll port GeShi\[1\]? Victor. GeSHi - Generic Syntax Highlighter :: Home

---

## ["classes are always open" for anonymous classes?](https://www.ruby-forum.com/t/classes-are-always-open-for-anonymous-classes/59426)

<div class="topic-metadata">

**Author:** [@joshmh](https://www.ruby-forum.com/u/joshmh)\
**Replies:** 3\
**Last updated:** [May 3, 2006, 7:05pm UTC](https://www.ruby-forum.com/t/classes-are-always-open-for-anonymous-classes/59426 "2006-05-03T19:05:42Z")

</div>

So you know how classes are always open? What about anonymous classes? I try: x = Class.new class x def foo end end but get: SyntaxError: compile error (irb):2: class/module name must be CONSTANT from (irb):5 …

---

## [Mailing list -\> ruby-forum.com broken?](https://www.ruby-forum.com/t/mailing-list-ruby-forum-com-broken/59403)

<div class="topic-metadata">

**Author:** [@justincollins](https://www.ruby-forum.com/u/justincollins)\
**Replies:** 1\
**Last updated:** [May 3, 2006, 7:04pm UTC](https://www.ruby-forum.com/t/mailing-list-ruby-forum-com-broken/59403 "2006-05-03T19:04:57Z")

</div>

It looks like messages sent to the mailing list are not being propagated to the ruby-forum.com. Some examples: “Mixin Syntax for Newbies” thread (started on forum, replies from mailing list not showing up) “YAML in …

---

## [Resolv-replace issue](https://www.ruby-forum.com/t/resolv-replace-issue/59420)

<div class="topic-metadata">

**Author:** [@Curtis\_Spencer](https://www.ruby-forum.com/u/Curtis_Spencer)\
**Replies:** 1\
**Last updated:** [May 3, 2006, 7:03pm UTC](https://www.ruby-forum.com/t/resolv-replace-issue/59420 "2006-05-03T19:03:49Z")

</div>

Hi, I am trying to get some more parallelism out of a crawler I wrote by using resolv-replace, but I can’t seem to get it to correctly resolve addresses. I tryed the following code: require ‘net/http’ require ‘open…

---

## [From block to code (also: how to get the bindings of a block](https://www.ruby-forum.com/t/from-block-to-code-also-how-to-get-the-bindings-of-a-block/58939)

<div class="topic-metadata">

**Author:** [@chiaroscuro](https://www.ruby-forum.com/u/chiaroscuro)\
**Replies:** 33\
**Last updated:** [May 3, 2006, 7:02pm UTC](https://www.ruby-forum.com/t/from-block-to-code-also-how-to-get-the-bindings-of-a-block/58939 "2006-05-03T19:02:47Z")

</div>

Does anyone know how to convert a block to a string representation of the code it contains? I would need that to inject some code within a block and evaluate the resulting code. I cannot simply append the code becau…

---

## [Restricting view to source code with RDOC?](https://www.ruby-forum.com/t/restricting-view-to-source-code-with-rdoc/59364)

<div class="topic-metadata">

**Author:** [@phallstrom](https://www.ruby-forum.com/u/phallstrom)\
**Replies:** 5\
**Last updated:** [May 3, 2006, 7:02pm UTC](https://www.ruby-forum.com/t/restricting-view-to-source-code-with-rdoc/59364 "2006-05-03T19:02:26Z")

</div>

Hi - I’d like to generate some docuementation using RDOC, but don’t want any of the “source” links available. I’ve seen some existing rdoc that does this, but don’t see an option within rdoc itself to exclude them. …

---

## [Toronto Ruby User Group Meeting - 7 May 2006](https://www.ruby-forum.com/t/toronto-ruby-user-group-meeting-7-may-2006/59411)

<div class="topic-metadata">

**Author:** [@mschwab](https://www.ruby-forum.com/u/mschwab)\
**Replies:** 0\
**Last updated:** [May 3, 2006, 7:02pm UTC](https://www.ruby-forum.com/t/toronto-ruby-user-group-meeting-7-may-2006/59411 "2006-05-03T19:02:03Z")

</div>

It’s nearly time for the Toronto Ruby U. Group to meet again - the next scheduled meeting is on Sun 7 May 2006 at the Linux Caffe in Toronto at 13:00. See http://www.trug.ca/Meetings for more details about TRUG meetin…

---

## [Re: parsedate doesn't work on Time.now.to\_s](https://www.ruby-forum.com/t/re-parsedate-doesnt-work-on-time-now-to-s/94418)

<div class="topic-metadata">

**Author:** [@BergerS\_Daniel](https://www.ruby-forum.com/u/BergerS_Daniel)\
**Replies:** 0\
**Last updated:** [May 3, 2006, 7:01pm UTC](https://www.ruby-forum.com/t/re-parsedate-doesnt-work-on-time-now-to-s/94418 "2006-05-03T19:01:38Z")

</div>

ParseDate.parsedate(Time.now.to\_s) =\> \[nil, 5, 2, 20, 17, 57, “GMT”, 2\] It seems that parsedate is not able to detect the year from the standard string conversion of a date/time. Is there another way to do this? Is…

---

## [\[ANN\] Radiant CMS](https://www.ruby-forum.com/t/ann-radiant-cms/94405)

<div class="topic-metadata">

**Author:** [@John\_WSLong](https://www.ruby-forum.com/u/John_WSLong)\
**Replies:** 18\
**Last updated:** [May 3, 2006, 7:00pm UTC](https://www.ruby-forum.com/t/ann-radiant-cms/94405 "2006-05-03T19:00:48Z")

</div>

I am pleased to announce that Radiant CMS is now publically available from the Subversion repository at: http://radiantcms.org/ What is Radiant? Radiant is a no-fluff, open source content management system designed …

---

## [Easy way to escape text for use in regexps?](https://www.ruby-forum.com/t/easy-way-to-escape-text-for-use-in-regexps/94370)

<div class="topic-metadata">

**Author:** [@weyus](https://www.ruby-forum.com/u/weyus)\
**Replies:** 2\
**Last updated:** [May 3, 2006, 7:00pm UTC](https://www.ruby-forum.com/t/easy-way-to-escape-text-for-use-in-regexps/94370 "2006-05-03T19:00:43Z")

</div>

I need to be able to include some arbitrary text as input into a regular expression and I’m looking for a way to escape regular expression metacharacters within my data(e.g. escape a “?” for example). Is there a libra…

---

## [Re: ot: spam (was RE: Text Munger (#76))](https://www.ruby-forum.com/t/re-ot-spam-was-re-text-munger-76/94129)

<div class="topic-metadata">

**Author:** [@PeSSSSaS\_Botp](https://www.ruby-forum.com/u/PeSSSSaS_Botp)\
**Replies:** 4\
**Last updated:** [May 3, 2006, 7:00pm UTC](https://www.ruby-forum.com/t/re-ot-spam-was-re-text-munger-76/94129 "2006-05-03T19:00:19Z")

</div>

Dave B. \[mailto:removed\_email\_address@domain.invalid\]: Wer mit Ungeheuern kämpft, mag zusehn, dass er nicht dabei zum Ungeheuer wird. Und wenn du lange in einen Abgrund blickst, blickt der Abgrund auch in dich hinei…

---

## [Urug/utahvalley.rb hacking night tonight](https://www.ruby-forum.com/t/urug-utahvalley-rb-hacking-night-tonight/59386)

<div class="topic-metadata">

**Author:** [@pat\_eyler](https://www.ruby-forum.com/u/pat_eyler)\
**Replies:** 2\
**Last updated:** [May 3, 2006, 7:00pm UTC](https://www.ruby-forum.com/t/urug-utahvalley-rb-hacking-night-tonight/59386 "2006-05-03T19:00:14Z")

</div>

the utahvalley.rb will be hackig tonight starting at 7PM in the Lab in room 2004 of the Talmage Math and Computer Science Building (TMCB) at BYU. Kevin and I are either going to work on coverity identified defects in…

---

## [Re: Calling Shell Scripts from Ruby?](https://www.ruby-forum.com/t/re-calling-shell-scripts-from-ruby/59396)

<div class="topic-metadata">

**Author:** [@Gennady\_B](https://www.ruby-forum.com/u/Gennady_B)\
**Replies:** 0\
**Last updated:** [May 3, 2006, 6:59pm UTC](https://www.ruby-forum.com/t/re-calling-shell-scripts-from-ruby/59396 "2006-05-03T18:59:52Z")

</div>

1)Is it possible to call “Shell Scripts” from ruby? Say if i have a shell sciprt named “test.sh”, how can i call this from ruby? Also if i can call like that,is it possible to get the output of that script passed bac…

---

## [How to get a new instance of a class given a String](https://www.ruby-forum.com/t/how-to-get-a-new-instance-of-a-class-given-a-string/59388)

<div class="topic-metadata">

**Author:** [@crucoba](https://www.ruby-forum.com/u/crucoba)\
**Replies:** 4\
**Last updated:** [May 3, 2006, 6:59pm UTC](https://www.ruby-forum.com/t/how-to-get-a-new-instance-of-a-class-given-a-string/59388 "2006-05-03T18:59:50Z")

</div>

Hey, I know I have seen his on the list before but I can’t seem to find it. I want to do something like class\_name = “UserPreference” up = Class.class\_for\_name(class\_name).new Anyone? Also, where would be a good pl…

---

## [Calling a block with some context](https://www.ruby-forum.com/t/calling-a-block-with-some-context/59379)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 1\
**Last updated:** [May 3, 2006, 6:59pm UTC](https://www.ruby-forum.com/t/calling-a-block-with-some-context/59379 "2006-05-03T18:59:38Z")

</div>

I would like to be able to call a block / proc / lambda with the current context (as well as the context it was created in): def make\_proc Proc.new {puts from\_calling\_context} end proc = make\_proc from\_calling\_cont…

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

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