# Ruby

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

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

---

## [Linux: getting the "load" values without using "top"](https://www.ruby-forum.com/t/linux-getting-the-load-values-without-using-top/133553)

<div class="topic-metadata">

**Author:** [@jimdeuc](https://www.ruby-forum.com/u/jimdeuc)\
**Replies:** 11\
**Last updated:** [April 1, 2008, 7:58pm UTC](https://www.ruby-forum.com/t/linux-getting-the-load-values-without-using-top/133553 "2008-04-01T19:58:57Z")

</div>

I would like to get some of the information provided by the “top” command into my ruby program, in particular the “load” values. The only way I can think of is to use popen3 to run “top -n 1” and parse the output, bu…

---

## [IMPORTANT: Posting to the ruby-talk ML through Google Groups](https://www.ruby-forum.com/t/important-posting-to-the-ruby-talk-ml-through-google-groups/133565)

<div class="topic-metadata">

**Author:** [@Trans](https://www.ruby-forum.com/u/Trans)\
**Replies:** 0\
**Last updated:** [April 1, 2008, 6:26pm UTC](https://www.ruby-forum.com/t/important-posting-to-the-ruby-talk-ml-through-google-groups/133565 "2008-04-01T18:26:42Z")

</div>

Important Notice for Google Group users. You will need to be subscribed to ruby-talk ML even when posting through the Google G. web interface. If you aren’t subscribed to the ML Google G. will NOT warn you. Your mail…

---

## [The problem use Ruby call com method and event](https://www.ruby-forum.com/t/the-problem-use-ruby-call-com-method-and-event/133320)

<div class="topic-metadata">

**Author:** [@tchg](https://www.ruby-forum.com/u/tchg)\
**Replies:** 2\
**Last updated:** [April 1, 2008, 5:41pm UTC](https://www.ruby-forum.com/t/the-problem-use-ruby-call-com-method-and-event/133320 "2008-04-01T17:41:21Z")

</div>

there are some problem when i use ruby call com method and event. the com programm i use mfc ccmdtarget classs,and i use vb for client call this com’s method and event,it’s ok. but ruby did not work,why?

---

## [Detaching free function from String in C API](https://www.ruby-forum.com/t/detaching-free-function-from-string-in-c-api/133542)

<div class="topic-metadata">

**Author:** [@absolute-beginner](https://www.ruby-forum.com/u/absolute-beginner)\
**Replies:** 2\
**Last updated:** [April 1, 2008, 4:36pm UTC](https://www.ruby-forum.com/t/detaching-free-function-from-string-in-c-api/133542 "2008-04-01T16:36:05Z")

</div>

Hi In a C extension, you can unset the ‘free’ function that will be called when an object is garbage collected with something like: RDATA(obj)-\>dfree = 0; This is useful if you know that whatever C library you’re int…

---

## [Simple and stable web server? Is there any?](https://www.ruby-forum.com/t/simple-and-stable-web-server-is-there-any/133541)

<div class="topic-metadata">

**Author:** [@axyd80](https://www.ruby-forum.com/u/axyd80)\
**Replies:** 6\
**Last updated:** [April 1, 2008, 4:05pm UTC](https://www.ruby-forum.com/t/simple-and-stable-web-server-is-there-any/133541 "2008-04-01T16:05:00Z")

</div>

Can you please advice a simple and stable web server in ruby? Requirements: -simplicity -session management In short i should implement an application with pure object database and desktop app like GUI (i.e. ideally…

---

## [Patch submitted - \[#19230\] Time implementation](https://www.ruby-forum.com/t/patch-submitted-19230-time-implementation/133504)

<div class="topic-metadata">

**Author:** [@nielsene](https://www.ruby-forum.com/u/nielsene)\
**Replies:** 1\
**Last updated:** [April 1, 2008, 4:01pm UTC](https://www.ruby-forum.com/t/patch-submitted-19230-time-implementation/133504 "2008-04-01T16:01:59Z")

</div>

Hey Guys, Josh C. put a bug in my ear (thanks Josh!), so I got off my duff and submitted a patch for the Time class that’s been sitting on my laptop for months. It should have implementations for most of the basic …

---

## [Referring to previously overridden method without subclass](https://www.ruby-forum.com/t/referring-to-previously-overridden-method-without-subclass/133545)

<div class="topic-metadata">

**Author:** [@ole](https://www.ruby-forum.com/u/ole)\
**Replies:** 3\
**Last updated:** [April 1, 2008, 3:37pm UTC](https://www.ruby-forum.com/t/referring-to-previously-overridden-method-without-subclass/133545 "2008-04-01T15:37:13Z")

</div>

I’m trying to debug a bit of code. I want to output all the parameters passed to PGconn#exec each time it is called but still have the method function as it should. I tried this: class PGconn def exec(\*args) puts “…

---

## [Displaying gruff graphs](https://www.ruby-forum.com/t/displaying-gruff-graphs/133442)

<div class="topic-metadata">

**Author:** [@ribes](https://www.ruby-forum.com/u/ribes)\
**Replies:** 9\
**Last updated:** [April 1, 2008, 3:21pm UTC](https://www.ruby-forum.com/t/displaying-gruff-graphs/133442 "2008-04-01T15:21:38Z")

</div>

Team, Once a graph is written to disk, g.write(“filename.png”), how can it be displayed in Ruby? I would like to re-create the graph and re-displayed often enough to give the appearance of “real time” Thank you Vi…

---

## [Numbers of a record in an array](https://www.ruby-forum.com/t/numbers-of-a-record-in-an-array/132850)

<div class="topic-metadata">

**Author:** [@mihai](https://www.ruby-forum.com/u/mihai)\
**Replies:** 16\
**Last updated:** [April 1, 2008, 2:33pm UTC](https://www.ruby-forum.com/t/numbers-of-a-record-in-an-array/132850 "2008-04-01T14:33:34Z")

</div>

a have an array array=\[“a”,“b”,“c”,“a”,“b”\] how can i find the numbers of “a”, “b”,“c” items in the array?

---

## [Metrics rmagick problem](https://www.ruby-forum.com/t/metrics-rmagick-problem/133443)

<div class="topic-metadata">

**Author:** [@edbond](https://www.ruby-forum.com/u/edbond)\
**Replies:** 5\
**Last updated:** [April 1, 2008, 1:22pm UTC](https://www.ruby-forum.com/t/metrics-rmagick-problem/133443 "2008-04-01T13:22:50Z")

</div>

I get a strange rmagick result. I need to add a centered text to image. Draw#inspect tell me that all is good, but on result image text isn’t centered. See Parked at Loopia for code and link to result image. Thanks…

---

## [Write data into Excel Sheet](https://www.ruby-forum.com/t/write-data-into-excel-sheet/133400)

<div class="topic-metadata">

**Author:** [@pranjal\_jain](https://www.ruby-forum.com/u/pranjal_jain)\
**Replies:** 3\
**Last updated:** [April 1, 2008, 1:00pm UTC](https://www.ruby-forum.com/t/write-data-into-excel-sheet/133400 "2008-04-01T13:00:08Z")

</div>

Hi I am new to Ruby. can any one suggest me how we can write the data into the Excel Sheet from the array. Can we use the command like this $worksheet.Range(“b1:b12”).Insert = a\[k\] Can I insert in excel sheet via th…

---

## [\[fxruby\] FXImageFrame/SEL\_LEFTBUTTONRELEASE](https://www.ruby-forum.com/t/fxruby-fximageframe-sel-leftbuttonrelease/133539)

<div class="topic-metadata">

**Author:** [@klaashaas](https://www.ruby-forum.com/u/klaashaas)\
**Replies:** 0\
**Last updated:** [April 1, 2008, 12:50pm UTC](https://www.ruby-forum.com/t/fxruby-fximageframe-sel-leftbuttonrelease/133539 "2008-04-01T12:50:40Z")

</div>

Hi, I have a FXImageFrame widget and I would like it to show another image when I click on it. I’m having no luck with receiving a onclick via SEL\_LEFTBUTTONRELEASE. … imageframe=FXImageFrame.new(mainwindow,the\_imag…

---

## [Last Day for Ruby Mendicant Donations](https://www.ruby-forum.com/t/last-day-for-ruby-mendicant-donations/133445)

<div class="topic-metadata">

**Author:** [@naething](https://www.ruby-forum.com/u/naething)\
**Replies:** 2\
**Last updated:** [April 1, 2008, 12:45pm UTC](https://www.ruby-forum.com/t/last-day-for-ruby-mendicant-donations/133445 "2008-04-01T12:45:55Z")

</div>

Hi folks, Just a reminder that if you’d like to donate to the Ruby Mendicant project, donations are closing on April 1st, so today is the last day to make a contribution. http://pledgie.com/campaigns/571 Right now, …

---

## [Sockets, windoze, and threads](https://www.ruby-forum.com/t/sockets-windoze-and-threads/133450)

<div class="topic-metadata">

**Author:** [@ara\_howard](https://www.ruby-forum.com/u/ara_howard)\
**Replies:** 4\
**Last updated:** [April 1, 2008, 11:58am UTC](https://www.ruby-forum.com/t/sockets-windoze-and-threads/133450 "2008-04-01T11:58:22Z")

</div>

this works on \*nix and might on windoze - i don’t have a box near so cannot test… can someone give it a whirl and/or patch it to work? it should simply run forever: require ‘socket’ STDIN.sync = STDOUT.sync = STDERR.…

---

## [Query regarding disable check boxes](https://www.ruby-forum.com/t/query-regarding-disable-check-boxes/133517)

<div class="topic-metadata">

**Author:** [@Venu9955](https://www.ruby-forum.com/u/Venu9955)\
**Replies:** 1\
**Last updated:** [April 1, 2008, 9:53am UTC](https://www.ruby-forum.com/t/query-regarding-disable-check-boxes/133517 "2008-04-01T09:53:30Z")

</div>

Hi, I am getting difficult while capturing the disable check boxes in my application using DOM Inspector. Can anyone help me out how could we test the check boxes which are in disable state. I am getting nothing by …

---

## [Begin/rescue not behaving how I want](https://www.ruby-forum.com/t/begin-rescue-not-behaving-how-i-want/133511)

<div class="topic-metadata">

**Author:** [@nefigah](https://www.ruby-forum.com/u/nefigah)\
**Replies:** 3\
**Last updated:** [April 1, 2008, 9:22am UTC](https://www.ruby-forum.com/t/begin-rescue-not-behaving-how-i-want/133511 "2008-04-01T09:22:40Z")

</div>

So I have some code that routinely checks for email in a cron job. Most of the time it works great. However, sometimes it gets a timeout error, which is fine; it happens. The thing is, I don’t want it to clog up my lo…

---

## [Ruby/Informix 0.7.0](https://www.ruby-forum.com/t/ruby-informix-0-7-0/133514)

<div class="topic-metadata">

**Author:** [@Gerardo\_SSGSSS\_mez](https://www.ruby-forum.com/u/Gerardo_SSGSSS_mez)\
**Replies:** 1\
**Last updated:** [April 1, 2008, 9:10am UTC](https://www.ruby-forum.com/t/ruby-informix-0-7-0/133514 "2008-04-01T09:10:45Z")

</div>

I’m pleased to announce another release of Ruby/Informix, a Ruby library for connecting to IBM Informix. In this release you’ll find support for the INTERVAL data type, more handy methods and more and better documenta…

---

## [More precise Bignum#to\_f](https://www.ruby-forum.com/t/more-precise-bignum-to-f/133518)

<div class="topic-metadata">

**Author:** [@nobu](https://www.ruby-forum.com/u/nobu)\
**Replies:** 1\
**Last updated:** [April 1, 2008, 9:01am UTC](https://www.ruby-forum.com/t/more-precise-bignum-to-f/133518 "2008-04-01T09:01:55Z")

</div>

e$B$J$+$@$G$9!#e(B e$B$A$g$C$HIbF0\>.?tE@4X78e(B(e$B@53N$K$O4\]$a4X78e(B)e$B$r8+D\>$7$F$$$?$H$3$m!"e(B 2007-07-28 e$B$NLdBj$,%j%F%i%k0J30$G$OD\>$Ce(B e$B$F$$$J$$$3$H$K5$$E$-$^$7$?!#e(B e$B0J2\<$N%Q%C%A$G$O!"?te(B%e$B$+$ie…

---

## [Rexml to slow](https://www.ruby-forum.com/t/rexml-to-slow/133246)

<div class="topic-metadata">

**Author:** [@mihai](https://www.ruby-forum.com/u/mihai)\
**Replies:** 18\
**Last updated:** [April 1, 2008, 8:53am UTC](https://www.ruby-forum.com/t/rexml-to-slow/133246 "2008-04-01T08:53:09Z")

</div>

I have an xml file and sometimes i call the find\_first\_recursive method; when my xml file is small its working fine but when i have ~900 lines im waiting ~15 seconds to return me the wanted node and i want something f…

---

## [Assignment if key\_exist? in Hash](https://www.ruby-forum.com/t/assignment-if-key-exist-in-hash/133503)

<div class="topic-metadata">

**Author:** [@darren\_kirby](https://www.ruby-forum.com/u/darren_kirby)\
**Replies:** 7\
**Last updated:** [April 1, 2008, 8:29am UTC](https://www.ruby-forum.com/t/assignment-if-key-exist-in-hash/133503 "2008-04-01T08:29:26Z")

</div>

Hi all, I have a bunch of lines like: foo = some\_hash\[“some\_key”\] if some\_hash.has\_key?(“some\_key”) This feels awkward and cumbersome, so I would imagine there is a more idiomatic way to write it. Thanks, -d

---

## [Create A Distributable Ruby Program With Minimal Install](https://www.ruby-forum.com/t/create-a-distributable-ruby-program-with-minimal-install/133392)

<div class="topic-metadata">

**Author:** [@wrishel](https://www.ruby-forum.com/u/wrishel)\
**Replies:** 5\
**Last updated:** [April 1, 2008, 2:16am UTC](https://www.ruby-forum.com/t/create-a-distributable-ruby-program-with-minimal-install/133392 "2008-04-01T02:16:17Z")

</div>

Although I have started to use Ruby instead of Python, I very much miss one feature that I have not been able to find in Ruby. There is a Python utility that takes a python script, and creates a single installable fil…

---

## [Improvements to RDoc (ideas for GSoC)](https://www.ruby-forum.com/t/improvements-to-rdoc-ideas-for-gsoc/133307)

<div class="topic-metadata">

**Author:** [@papipo](https://www.ruby-forum.com/u/papipo)\
**Replies:** 9\
**Last updated:** [April 1, 2008, 1:37am UTC](https://www.ruby-forum.com/t/improvements-to-rdoc-ideas-for-gsoc/133307 "2008-04-01T01:37:36Z")

</div>

I’m a brazilian student wishing to participate in Google Summer of Code this year, and work on something related to RDoc. Before I finish my proposal, I’d like some community feedback on the ideas below First of all, …

---

## [Releasing an Object](https://www.ruby-forum.com/t/releasing-an-object/133483)

<div class="topic-metadata">

**Author:** [@sithadmin](https://www.ruby-forum.com/u/sithadmin)\
**Replies:** 0\
**Last updated:** [April 1, 2008, 12:11am UTC](https://www.ruby-forum.com/t/releasing-an-object/133483 "2008-04-01T00:11:48Z")

</div>

Hello, I’m working on a project for MS Exhcange, you can see my original post here: Ruby iterating over Exchange Mailboxes - Ruby - Ruby-Forum However, a colleague of mine told me that in order to rid of the error I …

---

## [Design patterns](https://www.ruby-forum.com/t/design-patterns/132072)

<div class="topic-metadata">

**Author:** [@danmcb](https://www.ruby-forum.com/u/danmcb)\
**Replies:** 11\
**Last updated:** [March 31, 2008, 11:26pm UTC](https://www.ruby-forum.com/t/design-patterns/132072 "2008-03-31T23:26:29Z")

</div>

Hi, are there some good tutorials or references about design patterns in ruby, which talk about mixins etc? I would really appreciate one because ruby is quite different from other languages (and more flexible) conce…

---

## [Why my posts appear twice?](https://www.ruby-forum.com/t/why-my-posts-appear-twice/133427)

<div class="topic-metadata">

**Author:** [@ribes](https://www.ruby-forum.com/u/ribes)\
**Replies:** 4\
**Last updated:** [March 31, 2008, 11:15pm UTC](https://www.ruby-forum.com/t/why-my-posts-appear-twice/133427 "2008-03-31T23:15:15Z")

</div>

Team, Somehow all my posts appears twice. Do anyone knows why and how I can prevent that annoying side effect? Thank you Victor

---

## [Object#singleton\_class](https://www.ruby-forum.com/t/object-singleton-class/133437)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 1\
**Last updated:** [March 31, 2008, 11:12pm UTC](https://www.ruby-forum.com/t/object-singleton-class/133437 "2008-03-31T23:12:55Z")

</div>

e$B$k$S$-$A$G$9!#e(B e$B$=$m$=$mFC0\[%/%i%9$rF@$k%a%=%C%I$rF3F~$7$F$bNI$$$N$G$O$J$$$G$7$g$&$+!)e(B e$BKh2s!Ve(B(class \<\< x; self; end)e$B!W$H=q$/$N$OH~$7$/$J$$$G$9$+$i!#e(B e$BL\>A0$O$=$N$^$^!Ve(BObject#singleton\_class…

---

## [How to restart the system with our code](https://www.ruby-forum.com/t/how-to-restart-the-system-with-our-code/133418)

<div class="topic-metadata">

**Author:** [@vamsi](https://www.ruby-forum.com/u/vamsi)\
**Replies:** 5\
**Last updated:** [March 31, 2008, 9:56pm UTC](https://www.ruby-forum.com/t/how-to-restart-the-system-with-our-code/133418 "2008-03-31T21:56:11Z")

</div>

Hi all, well, i thaught differently and want to know can any body help me to restart or shutdown an operating system with ruby code? if possible please reply, i think it may be possible…

---

## [Modifying FIX::\* method](https://www.ruby-forum.com/t/modifying-fix-method/133463)

<div class="topic-metadata">

**Author:** [@alexd](https://www.ruby-forum.com/u/alexd)\
**Replies:** 4\
**Last updated:** [March 31, 2008, 8:38pm UTC](https://www.ruby-forum.com/t/modifying-fix-method/133463 "2008-03-31T20:38:42Z")

</div>

I have a class such as Class Foo def initialize(x) @x = x end attr\_read :x end I want to be able to multiply a NUMERIC object by my Foo object and have it return a new Foo object with all the instance variables m…

---

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

<div class="topic-metadata">

**Author:** [@tonydm](https://www.ruby-forum.com/u/tonydm)\
**Replies:** 5\
**Last updated:** [March 31, 2008, 7:40pm UTC](https://www.ruby-forum.com/t/regular-expression-help/133243 "2008-03-31T19:40:58Z")

</div>

On to my next learning exercise. As I parse a file I need to pull an IP address out a line. Now I thought a regular expression would be the ticket, but it’s giving me a problem. The follow line is an example string…

---

## [Dokkit 0.3.0 released](https://www.ruby-forum.com/t/dokkit-0-3-0-released/133460)

<div class="topic-metadata">

**Author:** [@gendag](https://www.ruby-forum.com/u/gendag)\
**Replies:** 0\
**Last updated:** [March 31, 2008, 7:30pm UTC](https://www.ruby-forum.com/t/dokkit-0-3-0-released/133460 "2008-03-31T19:30:16Z")

</div>

Hi Folks, version 0.3.0 of dokkit has been released! 1 Changes from version 0.2.0 the core has been completely re-written to make it independent from rote 2 What’s dokkit? dokkit is an open source document generat…

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

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