# Ruby

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

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

---

## [Is this a Ruby bug in Dir on Windows?](https://www.ruby-forum.com/t/is-this-a-ruby-bug-in-dir-on-windows/118322)

<div class="topic-metadata">

**Author:** [@wemagor](https://www.ruby-forum.com/u/wemagor)\
**Replies:** 1\
**Last updated:** [October 26, 2007, 1:26am UTC](https://www.ruby-forum.com/t/is-this-a-ruby-bug-in-dir-on-windows/118322 "2007-10-26T01:26:56Z")

</div>

This was discussed on another thread, but I thought I’d ask the question here to see if this is a bug or if it should work this way. This line doesn’t seem work from the Windows root directory (C:) but works from a su…

---

## [Pop/push, shift/unshift](https://www.ruby-forum.com/t/pop-push-shift-unshift/118018)

<div class="topic-metadata">

**Author:** [@simonsaid](https://www.ruby-forum.com/u/simonsaid)\
**Replies:** 61\
**Last updated:** [October 25, 2007, 11:30pm UTC](https://www.ruby-forum.com/t/pop-push-shift-unshift/118018 "2007-10-25T23:30:31Z")

</div>

the inconsistency in naming bothers me. :stuck\_out\_tongue: I would imagine that it comes from push/pop being older, and shift/unshift being added later (probably I would guess that both of these are pre-ruby programmin…

---

## [Pricess ID](https://www.ruby-forum.com/t/pricess-id/118306)

<div class="topic-metadata">

**Author:** [@fishman2001](https://www.ruby-forum.com/u/fishman2001)\
**Replies:** 2\
**Last updated:** [October 25, 2007, 11:28pm UTC](https://www.ruby-forum.com/t/pricess-id/118306 "2007-10-25T23:28:45Z")

</div>

Hi, if I start a process in Ruby using the system(“some process”) how can I get the process id of the process I’ve just started? Cheers. Dan.

---

## [How to use ri with a new package](https://www.ruby-forum.com/t/how-to-use-ri-with-a-new-package/118132)

<div class="topic-metadata">

**Author:** [@RichardOnRails](https://www.ruby-forum.com/u/RichardOnRails)\
**Replies:** 3\
**Last updated:** [October 25, 2007, 9:35pm UTC](https://www.ruby-forum.com/t/how-to-use-ri-with-a-new-package/118132 "2007-10-25T21:35:52Z")

</div>

Hi All, I just used gem to install the package “sys-admin” from the RubyForge sysadmin project by Daniel B… The example that Daniel provided for using sys-admin worked fine. I’d like to use ri to display the RDoc doc…

---

## [How to control another TK application](https://www.ruby-forum.com/t/how-to-control-another-tk-application/118267)

<div class="topic-metadata">

**Author:** [@goal1860](https://www.ruby-forum.com/u/goal1860)\
**Replies:** 3\
**Last updated:** [October 25, 2007, 9:34pm UTC](https://www.ruby-forum.com/t/how-to-control-another-tk-application/118267 "2007-10-25T21:34:42Z")

</div>

I want to validate strings displayed in a TK application, how can I write rb program to communicate to it and extract the messages from GUI? Any module is good for that?

---

## [Flatten, rb\_check\_array\_type and proxy class](https://www.ruby-forum.com/t/flatten-rb-check-array-type-and-proxy-class/118145)

<div class="topic-metadata">

**Author:** [@tom\_wang](https://www.ruby-forum.com/u/tom_wang)\
**Replies:** 1\
**Last updated:** [October 25, 2007, 9:12pm UTC](https://www.ruby-forum.com/t/flatten-rb-check-array-type-and-proxy-class/118145 "2007-10-25T21:12:28Z")

</div>

Hi, I created a proxy class like this one: class SavingProxy attr\_reader :context delegate :class, :to =\> :context delegate :is\_a?, :to =\> :context delegate :inspect, :to =\> :context delegate :type, :to =\> :contex…

---

## [Starting Threads](https://www.ruby-forum.com/t/starting-threads/118311)

<div class="topic-metadata">

**Author:** [@flnative](https://www.ruby-forum.com/u/flnative)\
**Replies:** 4\
**Last updated:** [October 25, 2007, 7:42pm UTC](https://www.ruby-forum.com/t/starting-threads/118311 "2007-10-25T19:42:55Z")

</div>

Hi @all I’ve many different threads to run parallel. Some of these have a special feature. At the starttime, I decide with a variable, which threads must sleep for 5 ms. The others can start now. How can I realize th…

---

## ["Taint" and (internal) copy constructors](https://www.ruby-forum.com/t/taint-and-internal-copy-constructors/118262)

<div class="topic-metadata">

**Author:** [@curthibbs](https://www.ruby-forum.com/u/curthibbs)\
**Replies:** 6\
**Last updated:** [October 25, 2007, 7:24pm UTC](https://www.ruby-forum.com/t/taint-and-internal-copy-constructors/118262 "2007-10-25T19:24:13Z")

</div>

Currently, the copy constructors for the MutableString class will “lose” the taint flag on the string being copied. One practical consequence of this is that any builtins that store local copies of the MutableString…

---

## [MountainWest RubyConf 2008](https://www.ruby-forum.com/t/mountainwest-rubyconf-2008/118327)

<div class="topic-metadata">

**Author:** [@pat\_eyler](https://www.ruby-forum.com/u/pat_eyler)\
**Replies:** 0\
**Last updated:** [October 25, 2007, 7:21pm UTC](https://www.ruby-forum.com/t/mountainwest-rubyconf-2008/118327 "2007-10-25T19:21:17Z")

</div>

MountainWest RubyConf 2008 is scheduled for March 28 and 29, 2008. It will be in Salt Lake City, at the same great venue we had last year, and it is again our intent to record and make available all the talks under a …

---

## [Array of Pairs data structure?](https://www.ruby-forum.com/t/array-of-pairs-data-structure/118266)

<div class="topic-metadata">

**Author:** [@S-gw](https://www.ruby-forum.com/u/S-gw)\
**Replies:** 3\
**Last updated:** [October 25, 2007, 7:03pm UTC](https://www.ruby-forum.com/t/array-of-pairs-data-structure/118266 "2007-10-25T19:03:44Z")

</div>

In a language called Lasso I am used to a data structure of an array of pairs: $simpleArray = array( ‘color’, ‘shape’, ‘size’) $arrayofPairs = array( ‘color’ = ‘red’, ‘shape’ = ‘trapezoid’, ‘size’ = ‘small’) $simple…

---

## [Advice sought on Installing Ruby 1.9 on OSX](https://www.ruby-forum.com/t/advice-sought-on-installing-ruby-1-9-on-osx/118324)

<div class="topic-metadata">

**Author:** [@rykkers](https://www.ruby-forum.com/u/rykkers)\
**Replies:** 0\
**Last updated:** [October 25, 2007, 6:52pm UTC](https://www.ruby-forum.com/t/advice-sought-on-installing-ruby-1-9-on-osx/118324 "2007-10-25T18:52:37Z")

</div>

I gave in and got a macbook about a month ago, and I’m getting around to doing an install of Ruby 1.9. I’ve already got the macports version of Ruby 1.8 installed. That got put under /opt/local Before I do make/make …

---

## [Form Designer adding delegates](https://www.ruby-forum.com/t/form-designer-adding-delegates/118226)

<div class="topic-metadata">

**Author:** [@dermothogan](https://www.ruby-forum.com/u/dermothogan)\
**Replies:** 11\
**Last updated:** [October 25, 2007, 6:48pm UTC](https://www.ruby-forum.com/t/form-designer-adding-delegates/118226 "2007-10-25T18:48:44Z")

</div>

I’ve got most of the form designer working ok now, so I’m going to start working on the MSBuild, project & item integration. However, I’ve got a couple of problems/questions. IronRuby doesn’t like the delegate op as…

---

## [Unit testing add extra command line parameters](https://www.ruby-forum.com/t/unit-testing-add-extra-command-line-parameters/116100)

<div class="topic-metadata">

**Author:** [@chucky](https://www.ruby-forum.com/u/chucky)\
**Replies:** 4\
**Last updated:** [October 25, 2007, 6:07pm UTC](https://www.ruby-forum.com/t/unit-testing-add-extra-command-line-parameters/116100 "2007-10-25T18:07:48Z")

</div>

Hi, I the the following code: #!/usr/bin/ruby require ‘test/unit’ some ruby code class TestSomeClass \< Test::Unit::TestCase def setup # some setup end def test\_01\_firstTest # some assertion end def test\_02\_sec…

---

## [WIN32-GUITEST issue](https://www.ruby-forum.com/t/win32-guitest-issue/118300)

<div class="topic-metadata">

**Author:** [@goal1860](https://www.ruby-forum.com/u/goal1860)\
**Replies:** 2\
**Last updated:** [October 25, 2007, 5:25pm UTC](https://www.ruby-forum.com/t/win32-guitest-issue/118300 "2007-10-25T17:25:34Z")

</div>

Who used win32:guitest module? When I require it and run, got such an error: can’t find cygwin1.dll. I am confused with it.

---

## [Time Window (#144)](https://www.ruby-forum.com/t/time-window-144/118316)

<div class="topic-metadata">

**Author:** [@bbazzarrakk](https://www.ruby-forum.com/u/bbazzarrakk)\
**Replies:** 0\
**Last updated:** [October 25, 2007, 4:25pm UTC](https://www.ruby-forum.com/t/time-window-144/118316 "2007-10-25T16:25:11Z")

</div>

I’ve said it before, and I’ll say it again this time: I love the easy problems. I’m always impressed by the creativity in the solutions for them. The tricks solvers manage to sneak into their code are so great. Le…

---

## [Overcoming dynamic block evaluation](https://www.ruby-forum.com/t/overcoming-dynamic-block-evaluation/118305)

<div class="topic-metadata">

**Author:** [@braver](https://www.ruby-forum.com/u/braver)\
**Replies:** 2\
**Last updated:** [October 25, 2007, 3:36pm UTC](https://www.ruby-forum.com/t/overcoming-dynamic-block-evaluation/118305 "2007-10-25T15:36:38Z")

</div>

Greetings – I’m writing a reusable options module for my scripts. All scripts in the same project share most of the common command-line options. I’m relying on the optparse module to do it. The desired functionality…

---

## [Ruby and C# Integration](https://www.ruby-forum.com/t/ruby-and-c-integration/118237)

<div class="topic-metadata">

**Author:** [@moonshot](https://www.ruby-forum.com/u/moonshot)\
**Replies:** 4\
**Last updated:** [October 25, 2007, 2:59pm UTC](https://www.ruby-forum.com/t/ruby-and-c-integration/118237 "2007-10-25T14:59:00Z")

</div>

Does anyone know of a way or have any links for how to integrate c# and ruby? I’d like to be able to write ruby scripts for testing and have them talk to my c# program. Thanks.

---

## [Accessing SQL Server named instance](https://www.ruby-forum.com/t/accessing-sql-server-named-instance/118242)

<div class="topic-metadata">

**Author:** [@gregarican](https://www.ruby-forum.com/u/gregarican)\
**Replies:** 1\
**Last updated:** [October 25, 2007, 2:37pm UTC](https://www.ruby-forum.com/t/accessing-sql-server-named-instance/118242 "2007-10-25T14:37:23Z")

</div>

I apologize in advance for posting a Rails question in the general Ruby news group, but here goes. Does anyone know of a way I can configure my Rails app to access a SQL Server named instance? My version of Rails is a…

---

## [Token replacement & rake](https://www.ruby-forum.com/t/token-replacement-rake/118197)

<div class="topic-metadata">

**Author:** [@rob](https://www.ruby-forum.com/u/rob)\
**Replies:** 2\
**Last updated:** [October 25, 2007, 2:35pm UTC](https://www.ruby-forum.com/t/token-replacement-rake/118197 "2007-10-25T14:35:02Z")

</div>

Hi, I need to create some method of automating builds of my rails web app. It needs to be built repetitively with minor differences specified in a config file. I was planning to use rake for this, but I guess it will …

---

## [Time.now](https://www.ruby-forum.com/t/time-now/118296)

<div class="topic-metadata">

**Author:** [@Casimir](https://www.ruby-forum.com/u/Casimir)\
**Replies:** 3\
**Last updated:** [October 25, 2007, 1:45pm UTC](https://www.ruby-forum.com/t/time-now/118296 "2007-10-25T13:45:52Z")

</div>

What units does it output - with .to\_f or .to\_i? Doesn’t seem to be milliseconds. I could be wrong. Ruby-doc dogged me. Google said Jack Ruby was writing letters to his brother Earl and suggested japanese. :smiley: I…

---

## [Smallest peeve ever!](https://www.ruby-forum.com/t/smallest-peeve-ever/118273)

<div class="topic-metadata">

**Author:** [@maz](https://www.ruby-forum.com/u/maz)\
**Replies:** 3\
**Last updated:** [October 25, 2007, 1:17pm UTC](https://www.ruby-forum.com/t/smallest-peeve-ever/118273 "2007-10-25T13:17:12Z")

</div>

I’m sure there’s no chance of this ever changing but I’m disappointed that the integer method “step”: start.step(end, step\_size) ...wasn't more like: step\_size.step(start, end) ...I just like having the start and en…

---

## [Any one help me?](https://www.ruby-forum.com/t/any-one-help-me/118280)

<div class="topic-metadata">

**Author:** [@vellingiri](https://www.ruby-forum.com/u/vellingiri)\
**Replies:** 2\
**Last updated:** [October 25, 2007, 1:10pm UTC](https://www.ruby-forum.com/t/any-one-help-me/118280 "2007-10-25T13:10:46Z")

</div>

Dear friends, I am unable to findout the answers for this question? I am having one server socket program ans one client program. server program: \<----------------\> \<-----------------\> ./server.rb -p 1234 client p…

---

## ['DBI' gem not in JRuby](https://www.ruby-forum.com/t/dbi-gem-not-in-jruby/118290)

<div class="topic-metadata">

**Author:** [@ochomo](https://www.ruby-forum.com/u/ochomo)\
**Replies:** 0\
**Last updated:** [October 25, 2007, 12:30pm UTC](https://www.ruby-forum.com/t/dbi-gem-not-in-jruby/118290 "2007-10-25T12:30:42Z")

</div>

Hello, I have noted that the ‘DBI’ gem is not available in JRuby! what option do we have? – Ochomo

---

## [TCP Address binding /resolution](https://www.ruby-forum.com/t/tcp-address-binding-resolution/118285)

<div class="topic-metadata">

**Author:** [@ochomo](https://www.ruby-forum.com/u/ochomo)\
**Replies:** 2\
**Last updated:** [October 25, 2007, 12:04pm UTC](https://www.ruby-forum.com/t/tcp-address-binding-resolution/118285 "2007-10-25T12:04:41Z")

</div>

Hello, I have a small ruby server application that uses code like this: server = TCPServer.new(‘10.2.77.66’, 6060) the problem is that I can only access it on browser if I use: http://10.2.77.66:6060 instead i want …

---

## [Puts from #!, but with data structure chrome](https://www.ruby-forum.com/t/puts-from-but-with-data-structure-chrome/118279)

<div class="topic-metadata">

**Author:** [@S-gw](https://www.ruby-forum.com/u/S-gw)\
**Replies:** 3\
**Last updated:** [October 25, 2007, 11:50am UTC](https://www.ruby-forum.com/t/puts-from-but-with-data-structure-chrome/118279 "2007-10-25T11:50:01Z")

</div>

When playing with small scripts and using puts to output some results, I find it rather disappointing that outputting an array or hash does not have the data structure chrome of \[ \] and { } – I know IRB does this, but…

---

## [Undefined method \`now' for DateTime:Class (NoMethodError)](https://www.ruby-forum.com/t/undefined-method-now-for-datetime-class-nomethoderror/118030)

<div class="topic-metadata">

**Author:** [@NAKAMURAS\_Hiroshi](https://www.ruby-forum.com/u/NAKAMURAS_Hiroshi)\
**Replies:** 11\
**Last updated:** [October 25, 2007, 11:38am UTC](https://www.ruby-forum.com/t/undefined-method-now-for-datetime-class-nomethoderror/118030 "2007-10-25T11:38:20Z")

</div>

\-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 e$BEDCf$5$s!"$U$J$P$5$s!"e(B 0% ruby -rtime -e ‘DateTime.now’ -e:1: undefined method \`now’ for DateTime:Class (NoMethodError) e$B$3$l$C$F$J$s$H$+$J$j$^$9$+$Me(B? datee$…

---

## [Ruby Certification Test](https://www.ruby-forum.com/t/ruby-certification-test/117994)

<div class="topic-metadata">

**Author:** [@john\_old](https://www.ruby-forum.com/u/john_old)\
**Replies:** 38\
**Last updated:** [October 25, 2007, 10:18am UTC](https://www.ruby-forum.com/t/ruby-certification-test/117994 "2007-10-25T10:18:08Z")

</div>

In the Japanese page of Ruby Association, at http://www.ruby-assn.org/ releases/2007091901.html.ja There is an announcement about the Ruby P.ming Language Certification Test. It is available this starting this Octobe…

---

## [Need help parsing HTML with Hpricot](https://www.ruby-forum.com/t/need-help-parsing-html-with-hpricot/118269)

<div class="topic-metadata">

**Author:** [@maz](https://www.ruby-forum.com/u/maz)\
**Replies:** 3\
**Last updated:** [October 25, 2007, 9:50am UTC](https://www.ruby-forum.com/t/need-help-parsing-html-with-hpricot/118269 "2007-10-25T09:50:04Z")

</div>

I’m having trouble understanding Hpricot (thanks to an abominable lack of documentation). I’m trying to parse HTML of the following nature: This is one line of text This is another line of text It keeps going on l…

---

## [URI::merge bug?](https://www.ruby-forum.com/t/uri-merge-bug/104468)

<div class="topic-metadata">

**Author:** [@regularfry](https://www.ruby-forum.com/u/regularfry)\
**Replies:** 16\
**Last updated:** [October 25, 2007, 9:04am UTC](https://www.ruby-forum.com/t/uri-merge-bug/104468 "2007-10-25T09:04:59Z")

</div>

Hi all, I’m not sure whether this is a bug: irb(main):013:0\> a = URI.parse(“http://www.example.com/foo/bar?a=b”) =\> #\<URI::HTTP:0xfdbb6d160 URL:http://www.example.com/foo/bar?a=b\> irb(main):014:0\> b = URI.parse(“?a=c…

---

## [Main-2.2.0](https://www.ruby-forum.com/t/main-2-2-0/118201)

<div class="topic-metadata">

**Author:** [@ara.t.howard](https://www.ruby-forum.com/u/ara.t.howard)\
**Replies:** 2\
**Last updated:** [October 25, 2007, 9:03am UTC](https://www.ruby-forum.com/t/main-2-2-0/118201 "2007-10-25T09:03:49Z")

</div>

NAME main.rb SYNOPSIS a class factory and dsl for generating command line programs real quick URI http://rubyforge.org/projects/codeforpeople/ http://codeforpeople.com/lib/ruby/ INSTALL gem install main HISTORY …

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

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