# Ruby

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

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

---

## [Module/file-scoped "global" variables?](https://www.ruby-forum.com/t/module-file-scoped-global-variables/101181)

<div class="topic-metadata">

**Author:** [@elgato](https://www.ruby-forum.com/u/elgato)\
**Replies:** 1\
**Last updated:** [August 3, 2006, 3:00pm UTC](https://www.ruby-forum.com/t/module-file-scoped-global-variables/101181 "2006-08-03T15:00:52Z")

</div>

Hello, I have a file with some functions which share some common variables. I want to have these functions visible in whole program (or at least in some classes by making a module from the file and mix it into these …

---

## [Ruby MySQL Gem uses older client library](https://www.ruby-forum.com/t/ruby-mysql-gem-uses-older-client-library/101001)

<div class="topic-metadata">

**Author:** [@paul-au](https://www.ruby-forum.com/u/paul-au)\
**Replies:** 2\
**Last updated:** [August 3, 2006, 2:35pm UTC](https://www.ruby-forum.com/t/ruby-mysql-gem-uses-older-client-library/101001 "2006-08-03T14:35:13Z")

</div>

Hi there, can ayone enlighten me on why I Ruby (using MySQl gem) would use an older client library. I have an XP box for developing and an Ubuntu box for deployment. Both have 5.x clients installed. The ubuntu still h…

---

## [Re: A left-exclusive Range class](https://www.ruby-forum.com/t/re-a-left-exclusive-range-class/101096)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 6\
**Last updated:** [August 3, 2006, 2:33pm UTC](https://www.ruby-forum.com/t/re-a-left-exclusive-range-class/101096 "2006-08-03T14:33:49Z")

</div>

The current Range class in ruby is quite useful, however, I was recently trying to capture a simple algorithm and ended up needing to express left-exclusion. Can you tell me what that algorithm was ? It may be bli…

---

## [RubyConf 2006 registration is open](https://www.ruby-forum.com/t/rubyconf-2006-registration-is-open/101168)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 3\
**Last updated:** [August 3, 2006, 2:24pm UTC](https://www.ruby-forum.com/t/rubyconf-2006-registration-is-open/101168 "2006-08-03T14:24:46Z")

</div>

Hi – Registration for RubyConf 2006 is now open, at http://www.regonline.com/101503. Please note that we are accepting credit cards only. There’s more conference info at http://www.rubyconf.org. Thanks – David for…

---

## [JRuby Extras - making Ruby apps spectacular in the Java worl](https://www.ruby-forum.com/t/jruby-extras-making-ruby-apps-spectacular-in-the-java-worl/101185)

<div class="topic-metadata">

**Author:** [@Charles\_O\_Nutter](https://www.ruby-forum.com/u/Charles_O_Nutter)\
**Replies:** 5\
**Last updated:** [August 3, 2006, 2:24pm UTC](https://www.ruby-forum.com/t/jruby-extras-making-ruby-apps-spectacular-in-the-java-worl/101185 "2006-08-03T14:24:45Z")

</div>

I’m happy to announce the JRuby Extras project, on RubyForge as jruby-extras. This project is intended to be a community-maintained nursery of plugins and extensions to extend JRuby’s capabilities and to provide Java…

---

## [RLisp - Lisp naturally embedded in Ruby](https://www.ruby-forum.com/t/rlisp-lisp-naturally-embedded-in-ruby/99561)

<div class="topic-metadata">

**Author:** [@fmwr](https://www.ruby-forum.com/u/fmwr)\
**Replies:** 31\
**Last updated:** [August 3, 2006, 2:24pm UTC](https://www.ruby-forum.com/t/rlisp-lisp-naturally-embedded-in-ruby/99561 "2006-08-03T14:24:41Z")

</div>

Hello :slight\_smile: Maybe some of you guys will be interested. I wrote a small Lisp interpretter embedded in Ruby. The emdedding is very tight - Lisp macros are Ruby Proc objects and Lisp lists are Ruby Arrays (so a…

---

## [Article: Ruby for the Java world](https://www.ruby-forum.com/t/article-ruby-for-the-java-world/98887)

<div class="topic-metadata">

**Author:** [@jamal86](https://www.ruby-forum.com/u/jamal86)\
**Replies:** 4\
**Last updated:** [August 3, 2006, 2:24pm UTC](https://www.ruby-forum.com/t/article-ruby-for-the-java-world/98887 "2006-08-03T14:24:31Z")

</div>

Just passing along an article reference that was brought to my attention. Ruby for the Java world July 2006 http://www.javaworld.com/javaworld/jw-07-2006/jw-0717-ruby.html Jamal

---

## [Sweet Lord!](https://www.ruby-forum.com/t/sweet-lord/97615)

<div class="topic-metadata">

**Author:** [@dasch](https://www.ruby-forum.com/u/dasch)\
**Replies:** 21\
**Last updated:** [August 3, 2006, 2:24pm UTC](https://www.ruby-forum.com/t/sweet-lord/97615 "2006-08-03T14:24:20Z")

</div>

Why haven’t I thought of this before? class Terminal include Enumerable def each(&block) while input = gets block.call(input.chomp) end end end terminal = Terminal.new terminate the loop with ctrl-d, o…

---

## [IF test in FOR loop](https://www.ruby-forum.com/t/if-test-in-for-loop/97603)

<div class="topic-metadata">

**Author:** [@Josselin](https://www.ruby-forum.com/u/Josselin)\
**Replies:** 4\
**Last updated:** [August 3, 2006, 2:24pm UTC](https://www.ruby-forum.com/t/if-test-in-for-loop/97603 "2006-08-03T14:24:19Z")

</div>

is it possible to test a condition (true-false) for each element in a loop like this : for user in @users (user.has\_role? (‘manager’)) … end or shoudl I write an if condition inside the loop : for user in @users …

---

## [Newbie Q - calling a method for an object in an .each block?](https://www.ruby-forum.com/t/newbie-q-calling-a-method-for-an-object-in-an-each-block/97586)

<div class="topic-metadata">

**Author:** [@mercan01](https://www.ruby-forum.com/u/mercan01)\
**Replies:** 9\
**Last updated:** [August 3, 2006, 2:24pm UTC](https://www.ruby-forum.com/t/newbie-q-calling-a-method-for-an-object-in-an-each-block/97586 "2006-08-03T14:24:16Z")

</div>

Hello All. Sorry if this is obvious, but I have looked over the list (and pickax) and not been able to solve it. I am trying to iterate over a collection of objects, calling a method defined within each object. I ha…

---

## [Libhxml Node#remove! kills each loop and extension to #\<\<](https://www.ruby-forum.com/t/libhxml-node-remove-kills-each-loop-and-extension-to/97581)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 5\
**Last updated:** [August 3, 2006, 2:24pm UTC](https://www.ruby-forum.com/t/libhxml-node-remove-kills-each-loop-and-extension-to/97581 "2006-08-03T14:24:15Z")

</div>

hi, While using #each to loop thru the children of a Node, if I remove a node the loop breaks on it’s own. root.each { |node| if XML::Node === node node.content = “yep” node.remove! if node\[‘id…

---

## [Task list in Eclipse](https://www.ruby-forum.com/t/task-list-in-eclipse/97523)

<div class="topic-metadata">

**Author:** [@casper\_the\_ghost](https://www.ruby-forum.com/u/casper_the_ghost)\
**Replies:** 3\
**Last updated:** [August 3, 2006, 2:24pm UTC](https://www.ruby-forum.com/t/task-list-in-eclipse/97523 "2006-08-03T14:24:13Z")

</div>

Eclipse automatically creates a task list when you write comments like this in your ruby code. TODO: fix this The task list is supposed to be updated when the file is saved, but for me it is only updated when Eclipse …

---

## [Make this code more Rubyish](https://www.ruby-forum.com/t/make-this-code-more-rubyish/97573)

<div class="topic-metadata">

**Author:** [@sweatje](https://www.ruby-forum.com/u/sweatje)\
**Replies:** 6\
**Last updated:** [August 3, 2006, 2:24pm UTC](https://www.ruby-forum.com/t/make-this-code-more-rubyish/97573 "2006-08-03T14:24:13Z")

</div>

I have the following code I pounded out today. It works, but it feels more like Perl than Ruby to me. Can anyone offer some suggestions for how to improve the readability of it? dev = /^SLOC.(?=^Totals grouped by)/i…

---

## [Sending mail through gmail](https://www.ruby-forum.com/t/sending-mail-through-gmail/97282)

<div class="topic-metadata">

**Author:** [@the-companion](https://www.ruby-forum.com/u/the-companion)\
**Replies:** 6\
**Last updated:** [August 3, 2006, 2:24pm UTC](https://www.ruby-forum.com/t/sending-mail-through-gmail/97282 "2006-08-03T14:24:11Z")

</div>

Hi. Could someone give me an example of how to send mail through a gmail account using the Ruby Net::SMTP class? Park H.'s gmailer library doesn’t work for me. Thanks

---

## [Gem mirrors list and main server outage](https://www.ruby-forum.com/t/gem-mirrors-list-and-main-server-outage/63916)

<div class="topic-metadata">

**Author:** [@Ed\_Howland](https://www.ruby-forum.com/u/Ed_Howland)\
**Replies:** 3\
**Last updated:** [August 3, 2006, 2:24pm UTC](https://www.ruby-forum.com/t/gem-mirrors-list-and-main-server-outage/63916 "2006-08-03T14:24:04Z")

</div>

Hi, during today’s rubyforge maintenance outage, I could not update/install my gems. I understood these were served by mirrors and that you automatically got redirected. Is it because the redirection happened on the s…

---

## [Whats new/fixed in Ruby 1.9 and Ruby 2.0](https://www.ruby-forum.com/t/whats-new-fixed-in-ruby-1-9-and-ruby-2-0/63586)

<div class="topic-metadata">

**Author:** [@rpw](https://www.ruby-forum.com/u/rpw)\
**Replies:** 48\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/whats-new-fixed-in-ruby-1-9-and-ruby-2-0/63586 "2006-08-03T14:23:59Z")

</div>

I was looking for a list of what is to be fixed or added to version 1.9 and what is slated for Ruby 2.0. Can someone point me in the right direction? Thanks

---

## [A plan for another unicode string hack](https://www.ruby-forum.com/t/a-plan-for-another-unicode-string-hack/95812)

<div class="topic-metadata">

**Author:** [@Dae\_San\_H](https://www.ruby-forum.com/u/Dae_San_H)\
**Replies:** 27\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/a-plan-for-another-unicode-string-hack/95812 "2006-08-03T14:23:57Z")

</div>

Hi everyone. I’m implementing yet another unicode string hacks. I’m trying to rewire String class so that it will act like Ruby 2.0 String class. (see http://redhanded.hobix.com/inspect/futurismUnicodeInRuby.html) St…

---

## [How to create classes automatically](https://www.ruby-forum.com/t/how-to-create-classes-automatically/101154)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 3\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/how-to-create-classes-automatically/101154 "2006-08-03T14:23:47Z")

</div>

hi let’s say I have a string with a class name as a value. I want to create a new instance of the class with the given class name. example: when I have a string like this: str = “Array” I want to create a new Array…

---

## [Subversion Bindings](https://www.ruby-forum.com/t/subversion-bindings/101043)

<div class="topic-metadata">

**Author:** [@matterker](https://www.ruby-forum.com/u/matterker)\
**Replies:** 1\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/subversion-bindings/101043 "2006-08-03T14:23:47Z")

</div>

Does anyone know where there is documentation for the Subversion bindings for Ruby? gr, Matthew

---

## [Langhelp-0.9.7](https://www.ruby-forum.com/t/langhelp-0-9-7/101191)

<div class="topic-metadata">

**Author:** [@unknown](https://www.ruby-forum.com/u/unknown)\
**Replies:** 0\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/langhelp-0-9-7/101191 "2006-08-03T14:23:43Z")

</div>

Hi, == Abstract Langhelp creates an index of documents of various programming languages and shell commands. Langhelp enables you to search documents instantly in Emacs. If you are a programmer, then you may sometime…

---

## [Interfacing with local ports](https://www.ruby-forum.com/t/interfacing-with-local-ports/101175)

<div class="topic-metadata">

**Author:** [@jasonlally](https://www.ruby-forum.com/u/jasonlally)\
**Replies:** 0\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/interfacing-with-local-ports/101175 "2006-08-03T14:23:33Z")

</div>

I have a very broad question to ask here. I’ll start with the scenario. I need to develop a ruby application that will take input from a device attached to a USB port on a computer and convert it to a web readable f…

---

## [Telnet Server in Ruby](https://www.ruby-forum.com/t/telnet-server-in-ruby/100792)

<div class="topic-metadata">

**Author:** [@dale](https://www.ruby-forum.com/u/dale)\
**Replies:** 10\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/telnet-server-in-ruby/100792 "2006-08-03T14:23:32Z")

</div>

Does anyone know of a Telnet Server written purely in Ruby? It doesn’t have to be fully featured. I just need a remote shell for control of an application that I am working on. Telnet is the preferred method since the…

---

## [Does one-click install leave other installs intact?](https://www.ruby-forum.com/t/does-one-click-install-leave-other-installs-intact/101125)

<div class="topic-metadata">

**Author:** [@bradjpeek](https://www.ruby-forum.com/u/bradjpeek)\
**Replies:** 4\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/does-one-click-install-leave-other-installs-intact/101125 "2006-08-03T14:23:29Z")

</div>

In the process of learning Ruby, so this is a newbie question… I used the one-click (windows) Ruby install to install Ruby 1.8.4 and afterwards I installed other Ruby classes such as OCI8 and Ruport. If I use the on…

---

## [Recc'd reading for regex work](https://www.ruby-forum.com/t/reccd-reading-for-regex-work/101171)

<div class="topic-metadata">

**Author:** [@xmg-eric](https://www.ruby-forum.com/u/xmg-eric)\
**Replies:** 0\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/reccd-reading-for-regex-work/101171 "2006-08-03T14:23:28Z")

</div>

This site does a masterful job of explaining regular expressions in ruby, java, & perl: The ruby page is a good starting point: And there is a printed book. I plan to have a copy on my bookshelf:

---

## [Cross-platform microsoft access parser](https://www.ruby-forum.com/t/cross-platform-microsoft-access-parser/101022)

<div class="topic-metadata">

**Author:** [@aran](https://www.ruby-forum.com/u/aran)\
**Replies:** 1\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/cross-platform-microsoft-access-parser/101022 "2006-08-03T14:23:27Z")

</div>

Hi, Is there an existing cross-platform library which can read microsoft access databases? Thank you!

---

## [Embedded Ruby Question](https://www.ruby-forum.com/t/embedded-ruby-question/100944)

<div class="topic-metadata">

**Author:** [@Brian\_Campbell](https://www.ruby-forum.com/u/Brian_Campbell)\
**Replies:** 8\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/embedded-ruby-question/100944 "2006-08-03T14:23:26Z")

</div>

Hi all, I want to embed Ruby in my C++ application. I’d like to read one or more Ruby scripts stored in my RDBMS, pass the Ruby script as a string (not a file name) to the interpreter, and have it execute the code. …

---

## [User space on rails open registration](https://www.ruby-forum.com/t/user-space-on-rails-open-registration/101164)

<div class="topic-metadata">

**Author:** [@Ryan\_McGovern](https://www.ruby-forum.com/u/Ryan_McGovern)\
**Replies:** 0\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/user-space-on-rails-open-registration/101164 "2006-08-03T14:23:25Z")

</div>

I am Happy To announce that USOR now allows for user registration aswell as the demo account. you can register here (http://usor.lerao.com/auth/register) or login with the demo account here (http://usor.lerao.com/auth…

---

## [How to split(//) with respect to bigraphs?](https://www.ruby-forum.com/t/how-to-split-with-respect-to-bigraphs/101123)

<div class="topic-metadata">

**Author:** [@elgato](https://www.ruby-forum.com/u/elgato)\
**Replies:** 9\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/how-to-split-with-respect-to-bigraphs/101123 "2006-08-03T14:23:24Z")

</div>

And once more question: In Czech, c followed by h is considered (for sorting etc.) as one character/grapheme ch. I need to split string to single characters with respect to this absurd manner. In Perl I can write sp…

---

## [Rubygems problem](https://www.ruby-forum.com/t/rubygems-problem/101160)

<div class="topic-metadata">

**Author:** [@jdonnell](https://www.ruby-forum.com/u/jdonnell)\
**Replies:** 0\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/rubygems-problem/101160 "2006-08-03T14:23:23Z")

</div>

I didn’t know where else to ask this so please point me in the right direction if there is a better place. I’m trying to install a gem, Ruby-MemCache from a local file. Here is what happens. test:~/tmp# gem install I…

---

## [Can't convert String into Integer (TypeError)](https://www.ruby-forum.com/t/cant-convert-string-into-integer-typeerror/101143)

<div class="topic-metadata">

**Author:** [@tim-hunter](https://www.ruby-forum.com/u/tim-hunter)\
**Replies:** 4\
**Last updated:** [August 3, 2006, 2:23pm UTC](https://www.ruby-forum.com/t/cant-convert-string-into-integer-typeerror/101143 "2006-08-03T14:23:19Z")

</div>

Okay, I’m stumped. I’ve been looking at this program off-and-on for 3 days now and I can’t understand why it’s failing like it does. It’s supposed to fail, but not the way it does. The Image#dissolve method takes 2 ar…

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

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