# Ruby

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

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

---

## [Block variable & Local variable](https://www.ruby-forum.com/t/block-variable-local-variable/192627)

<div class="topic-metadata">

**Author:** [@amiref](https://www.ruby-forum.com/u/amiref)\
**Replies:** 8\
**Last updated:** [August 10, 2010, 2:07am UTC](https://www.ruby-forum.com/t/block-variable-local-variable/192627 "2010-08-10T02:07:07Z")

</div>

Hi What does happen for “num” variable in this code : array = \[1,2,3,4,5\] x = 1 num = 1 array.each { |num| puts num\*20 + x } ( after this code when I type "puts num , ruby return 5 ! why? )

---

## [Haml view can't find helper function](https://www.ruby-forum.com/t/haml-view-cant-find-helper-function/193013)

<div class="topic-metadata">

**Author:** [@rainyglade](https://www.ruby-forum.com/u/rainyglade)\
**Replies:** 1\
**Last updated:** [August 10, 2010, 1:57am UTC](https://www.ruby-forum.com/t/haml-view-cant-find-helper-function/193013 "2010-08-10T01:57:01Z")

</div>

I have an object called Survey. There is a haml file: \\views\\surveys\\index.html.haml. The last line of the file is: = render :partial =\> ‘parameter\_results’, :locals =\>{:options =\> chart\_options(:n, :age) chart\_opt…

---

## [Accessing programs through the terminal with ruby](https://www.ruby-forum.com/t/accessing-programs-through-the-terminal-with-ruby/193004)

<div class="topic-metadata">

**Author:** [@kaspir](https://www.ruby-forum.com/u/kaspir)\
**Replies:** 5\
**Last updated:** [August 9, 2010, 11:05pm UTC](https://www.ruby-forum.com/t/accessing-programs-through-the-terminal-with-ruby/193004 "2010-08-09T23:05:12Z")

</div>

Specifically browsers. I’m trying to get a bunch of different browsers (FF, Opera, Safari, IE, Chrome, and Fock) to all open the same url/file location either 1) Simultaneously or 2) One after the other. Meaning one b…

---

## [Error messages from bash aren't captured by ruby interpreter](https://www.ruby-forum.com/t/error-messages-from-bash-arent-captured-by-ruby-interpreter/192994)

<div class="topic-metadata">

**Author:** [@steux](https://www.ruby-forum.com/u/steux)\
**Replies:** 2\
**Last updated:** [August 9, 2010, 10:00pm UTC](https://www.ruby-forum.com/t/error-messages-from-bash-arent-captured-by-ruby-interpreter/192994 "2010-08-09T22:00:38Z")

</div>

Hi everyone, How can I write a ruby script in order to capture error messagens from bash commands? if I do this: out = rm /var/mail/teste2 Errors like “rm: cannot remove \`/var/mail/teste2’: No such file or director…

---

## [Attributes in class](https://www.ruby-forum.com/t/attributes-in-class/192932)

<div class="topic-metadata">

**Author:** [@amiref](https://www.ruby-forum.com/u/amiref)\
**Replies:** 2\
**Last updated:** [August 9, 2010, 3:43pm UTC](https://www.ruby-forum.com/t/attributes-in-class/192932 "2010-08-09T15:43:24Z")

</div>

Hi Please help someone that knows C++ , and my question : Does “attribute” in ruby is same as “private member” in c++ ? if no please exactly explain me what is the concept of “attribute” in ruby?

---

## [Need help passing variable to Net::HTTP](https://www.ruby-forum.com/t/need-help-passing-variable-to-net-http/192952)

<div class="topic-metadata">

**Author:** [@shortnose](https://www.ruby-forum.com/u/shortnose)\
**Replies:** 8\
**Last updated:** [August 9, 2010, 1:14pm UTC](https://www.ruby-forum.com/t/need-help-passing-variable-to-net-http/192952 "2010-08-09T13:14:27Z")

</div>

I have used Net::HTTP like this: Net::HTTP.get ‘google.com’, ‘/index.html’ I would like to pass it a variable instead. I tried this: irb(main):001:0\> require ‘net/http’ =\> true irb(main):002:0\> url = String.new =\> …

---

## [One click installation to windows](https://www.ruby-forum.com/t/one-click-installation-to-windows/192858)

<div class="topic-metadata">

**Author:** [@rogerdpack](https://www.ruby-forum.com/u/rogerdpack)\
**Replies:** 2\
**Last updated:** [August 9, 2010, 11:39am UTC](https://www.ruby-forum.com/t/one-click-installation-to-windows/192858 "2010-08-09T11:39:35Z")

</div>

Anybody know of an easy way to get a one click installer for a jruby project that includes, for example, external dll’s and such? Looking for something that will add icons to the start menu, associate files, etc. Tha…

---

## [Looking for good Ruby OpenSSL TLS docs](https://www.ruby-forum.com/t/looking-for-good-ruby-openssl-tls-docs/192889)

<div class="topic-metadata">

**Author:** [@Aaron\_DSGifford](https://www.ruby-forum.com/u/Aaron_DSGifford)\
**Replies:** 3\
**Last updated:** [August 9, 2010, 11:01am UTC](https://www.ruby-forum.com/t/looking-for-good-ruby-openssl-tls-docs/192889 "2010-08-09T11:01:21Z")

</div>

Hi, I’ve got a custom TCP protocol that currently runs plaintext/cleartext to which I want to add something akin to SMTP’s STARTTLS. The scripts use Ruby’s TCPSockets. The protocol will for the most part remain une…

---

## [Dynamic require](https://www.ruby-forum.com/t/dynamic-require/192958)

<div class="topic-metadata">

**Author:** [@raj\_plays](https://www.ruby-forum.com/u/raj_plays)\
**Replies:** 2\
**Last updated:** [August 9, 2010, 8:29am UTC](https://www.ruby-forum.com/t/dynamic-require/192958 "2010-08-09T08:29:18Z")

</div>

Hi, Is there a syntax of ‘require’ that can dynamically pick up all source files searching in sub directories? I have many subdirectories under my root directory and each has some .rb files. The names and number of …

---

## [Where to host the Ruby Project Source Code](https://www.ruby-forum.com/t/where-to-host-the-ruby-project-source-code/192815)

<div class="topic-metadata">

**Author:** [@kadishmal](https://www.ruby-forum.com/u/kadishmal)\
**Replies:** 8\
**Last updated:** [August 9, 2010, 7:26am UTC](https://www.ruby-forum.com/t/where-to-host-the-ruby-project-source-code/192815 "2010-08-09T07:26:52Z")

</div>

Hi, I have created the Ruby Driver for CUBRID Database System. Currently working on ActiveRecord Adapter for CUBRID. The driver gem has already been pushed to RubyGems.org, so available through “gem install cubrid”. …

---

## [Expressive Languages for the JVM (JRuby/Mirah)](https://www.ruby-forum.com/t/expressive-languages-for-the-jvm-jruby-mirah/192957)

<div class="topic-metadata">

**Author:** [@jcain](https://www.ruby-forum.com/u/jcain)\
**Replies:** 0\
**Last updated:** [August 9, 2010, 7:04am UTC](https://www.ruby-forum.com/t/expressive-languages-for-the-jvm-jruby-mirah/192957 "2010-08-09T07:04:26Z")

</div>

Thought you guys might enjoy “Expressive Languages for the JVM”, a Google Tech Talk by Charles Oliver N., from Engine Y… http://www.youtube.com/watch?v=WlsD2FiBIbg The first half is on JRuby and talks about threading…

---

## [\[Bug #3598\] ruby crushes with Dir\[deep\_path\]](https://www.ruby-forum.com/t/bug-3598-ruby-crushes-with-dir-deep-path/191995)

<div class="topic-metadata">

**Author:** [@Usaku\_NAKAMURA](https://www.ruby-forum.com/u/Usaku_NAKAMURA)\
**Replies:** 2\
**Last updated:** [August 9, 2010, 6:47am UTC](https://www.ruby-forum.com/t/bug-3598-ruby-crushes-with-dir-deep-path/191995 "2010-08-09T06:47:28Z")

</div>

Bug #3598: ruby crushes with Dir\[deep\_path\] http://redmine.ruby-lang.org/issues/show/3598 e$B5/I\<\<Te(B: Usaku NAKAMURA e$B%9%F!\<%?%9e(B: Open, e$BM%@hEYe(B: Normal Target version: 1.9.x ruby -v: ruby 1.9.3dev (2010-…

---

## [Regarding win 32 screenshot](https://www.ruby-forum.com/t/regarding-win-32-screenshot/192703)

<div class="topic-metadata">

**Author:** [@vardhan\_patil](https://www.ruby-forum.com/u/vardhan_patil)\
**Replies:** 4\
**Last updated:** [August 8, 2010, 11:20pm UTC](https://www.ruby-forum.com/t/regarding-win-32-screenshot/192703 "2010-08-08T23:20:53Z")

</div>

Me using the latest version of gem win32screen shot… But while taking desktop screenshot i get undefined method \`call for nil:NilClass for capture\_area in bitmap maker.rb line 159 bitmap maker.rb line 127 and screen…

---

## [New in classes](https://www.ruby-forum.com/t/new-in-classes/192926)

<div class="topic-metadata">

**Author:** [@amiref](https://www.ruby-forum.com/u/amiref)\
**Replies:** 5\
**Last updated:** [August 8, 2010, 8:15pm UTC](https://www.ruby-forum.com/t/new-in-classes/192926 "2010-08-08T20:15:20Z")

</div>

Hi In the attached code what is the meaning of colored part of code? what is the meaning those codes that showed when I wrote “Test.new” and “variable = Test.new” ?

---

## [Configurability 1.0.1](https://www.ruby-forum.com/t/configurability-1-0-1/192941)

<div class="topic-metadata">

**Author:** [@mgreenly](https://www.ruby-forum.com/u/mgreenly)\
**Replies:** 0\
**Last updated:** [August 8, 2010, 7:53pm UTC](https://www.ruby-forum.com/t/configurability-1-0-1/192941 "2010-08-08T19:53:05Z")

</div>

Version 1.0.1 of configurability has been released. Configurability is a mixin that allows you to add configurability to one or more objects, assign them each a section of the configuration, and then when the config…

---

## [Is it possible to access memory as a block?](https://www.ruby-forum.com/t/is-it-possible-to-access-memory-as-a-block/192935)

<div class="topic-metadata">

**Author:** [@cyberjom](https://www.ruby-forum.com/u/cyberjom)\
**Replies:** 1\
**Last updated:** [August 8, 2010, 7:27pm UTC](https://www.ruby-forum.com/t/is-it-possible-to-access-memory-as-a-block/192935 "2010-08-08T19:27:20Z")

</div>

I have a situation to load large amount of data multi-million of data to memory for processing. It’s memory intensive application. Analysis. I have found that Hash is too slow, then I try Array but it’s overhead of 2…

---

## [Re: Attributes in class](https://www.ruby-forum.com/t/re-attributes-in-class/192934)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 0\
**Last updated:** [August 8, 2010, 6:51pm UTC](https://www.ruby-forum.com/t/re-attributes-in-class/192934 "2010-08-08T18:51:02Z")

</div>

Hi Attributes are as accessor methods for private field. You can use it for setting and getting value.

---

## [Loops](https://www.ruby-forum.com/t/loops/192914)

<div class="topic-metadata">

**Author:** [@midnightcoder](https://www.ruby-forum.com/u/midnightcoder)\
**Replies:** 5\
**Last updated:** [August 8, 2010, 1:06pm UTC](https://www.ruby-forum.com/t/loops/192914 "2010-08-08T13:06:23Z")

</div>

Hi, I’m only a newbie on ruby could someone help me with my code: Here’s: I’m writing a program which will ask the user to input a word or typed goodbye to quit the program. The first part is done the problems is that…

---

## [R: Re: \[jruby-user\] sqljdbc4.jar and rails 3](https://www.ruby-forum.com/t/r-re-jruby-user-sqljdbc4-jar-and-rails-3/192919)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [August 8, 2010, 12:20pm UTC](https://www.ruby-forum.com/t/r-re-jruby-user-sqljdbc4-jar-and-rails-3/192919 "2010-08-08T12:20:35Z")

</div>

macbook:teste fpellegrini$ pwd /Users/fpellegrini/teste macbook:teste fpellegrini$ $CLASSPATH -bash: /Users/fpellegrini/teste/lib/sqljdbc4.jar: Permission denied macbook:teste fpellegrini$ ls -la /Users/fpellegrini/…

---

## [Calendar hash](https://www.ruby-forum.com/t/calendar-hash/192915)

<div class="topic-metadata">

**Author:** [@landge](https://www.ruby-forum.com/u/landge)\
**Replies:** 0\
**Last updated:** [August 8, 2010, 10:42am UTC](https://www.ruby-forum.com/t/calendar-hash/192915 "2010-08-08T10:42:15Z")

</div>

Posted this in the rails group, but didn’t get an answer yet. maybe you can help me? Hi! I’m trying to create a nested hash which should hold the dates in my database as a kind of calendar. What I did so far is obvio…

---

## [Data::Dumper Request](https://www.ruby-forum.com/t/data-dumper-request/192769)

<div class="topic-metadata">

**Author:** [@brentmc79](https://www.ruby-forum.com/u/brentmc79)\
**Replies:** 3\
**Last updated:** [August 8, 2010, 9:23am UTC](https://www.ruby-forum.com/t/data-dumper-request/192769 "2010-08-08T09:23:16Z")

</div>

Hiya I know we can use JSON, YAML, Marshal etc for representation of the data. Personally I find the above solutions clunky. I would do the job if I could (Still learning Ruby), but im hoping with the spirit of open…

---

## [Where + how to download Shoes](https://www.ruby-forum.com/t/where-how-to-download-shoes/192894)

<div class="topic-metadata">

**Author:** [@h77bailey](https://www.ruby-forum.com/u/h77bailey)\
**Replies:** 1\
**Last updated:** [August 8, 2010, 9:13am UTC](https://www.ruby-forum.com/t/where-how-to-download-shoes/192894 "2010-08-08T09:13:54Z")

</div>

I’am trying to create an education database software,which can create analysis + reports, being new to programming I was advice to consider Ruby. After reading a very confusing Ruby, I was directed to Shoes. I have Wi…

---

## [\[ANN\] Detest 3.1.1](https://www.ruby-forum.com/t/ann-detest-3-1-1/192912)

<div class="topic-metadata">

**Author:** [@snk](https://www.ruby-forum.com/u/snk)\
**Replies:** 0\
**Last updated:** [August 8, 2010, 9:12am UTC](https://www.ruby-forum.com/t/ann-detest-3-1-1/192912 "2010-08-08T09:12:56Z")

</div>

Detest Assertion testing library for Ruby http://snk.tuxfamily.org/lib/detest/ Version 3.1.1 (2010-08-08) This release adds forgotten nil assertions and updates the h…

---

## [\[ANN\] Inochi 5.0.0](https://www.ruby-forum.com/t/ann-inochi-5-0-0/192910)

<div class="topic-metadata">

**Author:** [@snk](https://www.ruby-forum.com/u/snk)\
**Replies:** 0\
**Last updated:** [August 8, 2010, 8:55am UTC](https://www.ruby-forum.com/t/ann-inochi-5-0-0/192910 "2010-08-08T08:55:19Z")

</div>

Inochi Gives life to Ruby projects http://snk.tuxfamily.org/lib/inochi/ Version 5.0.0 (2010-08-07) This release switches from \[1\]\[Ronn\] to \[2\]\[AsciiDoc\] for writi…

---

## [Sqljdbc4.jar and rails 3](https://www.ruby-forum.com/t/sqljdbc4-jar-and-rails-3/192323)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 14\
**Last updated:** [August 8, 2010, 6:17am UTC](https://www.ruby-forum.com/t/sqljdbc4-jar-and-rails-3/192323 "2010-08-08T06:17:45Z")

</div>

I’m trying to set up a test project for a rails app using MS SQL server as backend database, but i cannot get it working. Dev env is Mac OSX Snow leopard, jruby 1.5.1, rails 3.0.0beta4 database is MS Sql server 2005 …

---

## [IronRubyMvc Update](https://www.ruby-forum.com/t/ironrubymvc-update/192903)

<div class="topic-metadata">

**Author:** [@ryan](https://www.ruby-forum.com/u/ryan)\
**Replies:** 2\
**Last updated:** [August 8, 2010, 5:43am UTC](https://www.ruby-forum.com/t/ironrubymvc-update/192903 "2010-08-08T05:43:48Z")

</div>

I just updated IronRubyMvc to IronRuby 1.0 (I know 1.1 is out, but I wanted this thing working, and I only had 1.0 for .NET 2.0) and ASP.NET MVC 2.0. Please feel free to test it out: GitHub - panesofglass/ironrubymv…

---

## [Call for Participation for 2010 Workshop on Scheme and Functional Programming](https://www.ruby-forum.com/t/call-for-participation-for-2010-workshop-on-scheme-and-functional-programming/192911)

<div class="topic-metadata">

**Author:** [@mrcfab3](https://www.ruby-forum.com/u/mrcfab3)\
**Replies:** 0\
**Last updated:** [August 8, 2010, 4:20am UTC](https://www.ruby-forum.com/t/call-for-participation-for-2010-workshop-on-scheme-and-functional-programming/192911 "2010-08-08T04:20:41Z")

</div>

\[The early registration deadline is only 2 days from now. Please register ASAP!\] CALL FOR PARTICIPATION 2010 Workshop on Scheme and Functional Programming Montreal, Quebec, Canada…

---

## [Question about sub-class of array](https://www.ruby-forum.com/t/question-about-sub-class-of-array/192905)

<div class="topic-metadata">

**Author:** [@warren\_ferguson](https://www.ruby-forum.com/u/warren_ferguson)\
**Replies:** 6\
**Last updated:** [August 8, 2010, 2:11am UTC](https://www.ruby-forum.com/t/question-about-sub-class-of-array/192905 "2010-08-08T02:11:06Z")

</div>

I don’t understand why thsi isn’t working. I wanted to introduce a subclass of the Array class called Bitvector. A bit vector is an array of 0s and 1s, ordered from lsb at index 0 to msb at the highest index, so “100…

---

## [Adding sugar to Ruby](https://www.ruby-forum.com/t/adding-sugar-to-ruby/192851)

<div class="topic-metadata">

**Author:** [@rbjl](https://www.ruby-forum.com/u/rbjl)\
**Replies:** 6\
**Last updated:** [August 8, 2010, 2:10am UTC](https://www.ruby-forum.com/t/adding-sugar-to-ruby/192851 "2010-08-08T02:10:45Z")

</div>

Hi, I’ve collected some nice little additions to Ruby and put them in a gem called zucker. Some of the features: control structure like iteration: iterate \[1,2\], \[3,4,5\] do |e,f| puts “#{e},#{f}” end outputs 1,…

---

## [Rake-compiler 0.7.1 Released](https://www.ruby-forum.com/t/rake-compiler-0-7-1-released/192904)

<div class="topic-metadata">

**Author:** [@luislavena](https://www.ruby-forum.com/u/luislavena)\
**Replies:** 0\
**Last updated:** [August 8, 2010, 1:52am UTC](https://www.ruby-forum.com/t/rake-compiler-0-7-1-released/192904 "2010-08-08T01:52:01Z")

</div>

rake-compiler version 0.7.1 has been released! http://github.com/luislavena/rake-compiler http://rubyforge.org/projects/rake-compiler = rake-compiler rake-compiler aims to help Gem developers deal with Ruby extension…

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

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