273066-300712 subjects 273604-274992

[ANN] October Vancouver Ruby/Rails Meetup Today (Oct/9 @ 7pm)
273387 [gbauer@e- ac] You're invited to join us for today's Ruby/Rails meetup in

Cannot post to gmane.comp.lang.ruby.general?
273393 [hs@db in .c ] I read that the gmane.comp.lang.ruby.general newsgroup is supposed to

File template as command line param?
273394 [hs@db in .c ] If I pass *.rb as a command line parameter to a Ruby script ARGV
+ 273397 [fwmailinglis] charset="us-ascii"
+ 273433 [lojicdotcom@] brian@imagine:~/temp$ cat > temp.rb

Ruby binary temp file
273395 [wimxa@ya oo ] require 'tempfile'
+ 273400 [djberg96@gm ] Not that I can see.
+ 273402 [james@gr yp ] #!/usr/bin/env ruby -wKU

Simple metaclass question
273404 [nlakkakula@g] module Mod
273414 [mental@ry ia] Ruby inheritance is linearized so that each module only appears once.
273418 [rick.denatal] For a while, about a year ago, Ruby 1.9 had changed the semantics of

Re: syntax: iter?
273412 [drbrain@se m] You are dreaming.
273463 [ryand-ruby@z] % echo "[].each {}" | parse_tree_show -

[ANN] Toronto Ruby Users Group Monthly Meeting, October 14, 1pm
273417 [halostatue@g] Just a reminder that the TRUG monthly meeting is this Sunday on

Re: your mail
273422 [perrin@ap th] Holy cow, it's too much fun to watch this program work. . . .
273424 [classified@y] ...
273429 [drbrain@se m] I tried out something like this with the GC subsystem, but I ended up

Finding shared elements between to arrays.
273423 [sebastian.pr] I am wondering if there is a really smart built in way to get an array
+ 273425 [badcarl@gm i] I think the operation you are looking for is a set intersection.  In
| 273427 [sebastian.pr] Nice Carl!
+ 273426 [rubytraining] On Oct 9, 5:46 pm, Sebastian probst Eide
  + 273431 [sebastian.pr] Yeah, I was wondering if there wasn't a better way than using map and
  + 273480 [shortcutter@] Just a caveat: for large Arrays it might be inefficient (I don't know
  | 273519 [sebastian.pr] I'll check it out!
  + 273524 [rick.denatal] The difference being that & eliminates duplicates from the result.
    + 273545 [rick.denatal] Heck, I use it so infrequently that I just thought of it. <G>
    + 273668 [rubytraining] Well a1 - (a1 - a2) is not necessarily the same as a2 - (a2 - a1).
      + 273698 [ed.odanow@wo] A "Ruby change request" - see http://rcrchive.net/
      + 273855 [rick.denatal] Yep, you're right, not enough test cases! <G>
        273876 [sebastian.pr] Well, I never really thought about the possibility of duplicates. In my
        273961 [shortcutter@] In that case you should probably use Set anyway as typical set

YAML to Struct
273435 [andrew@el as] Is it possible to take YAML and turn it into a Struct?  I want to take
+ 273440 [konrad@ty er] charset="utf-8"
| 273443 [andrew@el as] Awesome, thanks!  That looks like it should work.
+ 273458 [ara.t.howard] require 'yaml'
+ 273565 [andrew@el as] data = YAML::load(yaml_data).to_hash
+ 273571 [drbrain@se m] The easiest way is to create a MyStruct and add "--- !ruby/

reading files
273437 [fixxie.wits@] ...
+ 273444 [justincollin] person_name = File.read("somefile")
| 273456 [fixxie.wits@] ...
| 273465 [alexg@ku cr ] The syntax errors are because you have an extra 'end'. You also don't
| 273569 [fixxie.wits@] ...
+ 273452 [dolgun@ex it] data.txt

Migrating RubyForge to new hardware
273442 [tom@in oe he] We're migrating RubyForge to a new server this evening.  This will mean
+ 273479 [tom@in oe he] The migration is more or less complete; if you notice anything awry,
+ 273489 [Bil.Kleb@NA ] Thanks Tim!
| 273492 [jan.svitok@g] Sun X4200 M2 server (with a prodigious 8 GB of RAM)
+ 273908 [gerardo.sant] Thanks Tom for the great work.
  + 273909 [gerardo.sant] And my DNS already resolves rubyforge.org as
  + 273967 [tom@in oe he] Hm, that's weird... hm.  Thanks for the note, I emailed you and we'll

DBI stateHandler bind_param errors
273445 [davidslee9@g] I have a real problem with calling a stored procedure on MS SQL Server

Debugging rspec in Netbeans
273446 [richpoirier@] AFAIK, I'm supposed to be able to just do Command+Shift+F5 with the

Simple socket server not working?
273450 [sgware@gm il] Any idea why this code...
+ 273449 [sgware@gm il] (Just to avoid easy questions...)
| 273455 [sgware@gm il] Hmm... seem to have fixed my own problem.  I just removed the
| 273499 [ari@ar br wn] As a quick summary of the  problem, is ONLY accessible from
+ 273461 [botp@de mo t] # server = TCPServer.new('', 5056)
+ 273469 [schapht@gm i] A firewall perhaps?  Does it work locally but not from a remote
+ 273508 [jlsysinc@ho ] You probably want..
+ 273528 [martin.portm] Using the machine's network address. Something like

will #in? be in ruby2? (was Re: Finding shared elements between to arrays.)
273453 [botp@de mo t] a3 =3D a1.select { |e| e.in? a2}
+ 273460 [devi.webmast] ...
| 273466 [botp@de mo t] # >    a3 = a1.select { |e| e.in? a2}
| + 273472 [mortee.lists] Why don't you just define #in? in Object yourself, and then you can use
| | 273487 [dblack@ru yp] ...
| | 273502 [mortee.lists] method name collisions whithin a module/class coming from different sources.
| | 273610 [shortcutter@] what about an operator like "def_once" or "def!" which will raise an
| | 273641 [rick.denatal] Jim Weirich uses something like this in rake.  He defines a method
| + 273473 [alexg@ku cr ] If I understand you correctly the :in? method would have to be =20
|   + 273583 [botp@de mo t] # Daniel's point (I think) is that this pollutes the top=20
|   + 273733 [george.ogata] Just playing devil's advocate, but could the same thing not be said
|     273764 [shortcutter@] Hehe, very true.  I think the judgment whether to put a method in
+ 273471 [konrad@ty er] charset="iso-8859-1"
+ 273731 [george.ogata] Also, #& uses #eql? whereas #include? uses #== .

object to class...
273475 [bad_good_lio] is it possible to convert from a ruby object to Ruby class...
+ 273482 [alexg@ku cr ] I'm not sure what you mean, but every Object has a class method which
+ 273483 [sylvain.joye] What do you exactly have in mind ? Ruby classes are already Ruby
| 273495 [bad_good_lio] source code here
| + 273496 [bad_good_lio] source code here
| | 273782 [dangerwillro] You could start a ruby process that then loads a file, but before
| + 273497 [shortcutter@] If you want to create the class definition source code when having an
+ 273484 [shaiguitar@g] do u mean this?
  273500 [ari@ar br wn] Maybe he means something like extracting Ruby code for the class out
  273585 [botp@de mo t] # AFAIK, this is not possible. Take a look at ruby2ruby
  273586 [botp@de mo t] # arggh, i'm feeling dumb, i've just downloaded the gem, but i=20

Inter-Process Messaging
273481 [dan-ml@da 42] What are the possibilities in ruby for passing information from one
+ 273486 [mbj@se ni .n] shared memory?
| + 273529 [dan-ml@da 42] Is there a ruby lib to handle shared memory? Also, I can see how it can
| + 273564 [vjoel@pa h. ] Ditto. I've been using DRb over UNIX sockets extensively for about 2
+ 273511 [garbagecat10] ...
| 273527 [znmeb@ce ma ] There's also a Ruby MPI binding, but I'm not sure how well maintained it
| 273530 [james@gr yp ] I would go with a pipe, because it's easy and sounds like it's all
| 273536 [znmeb@ce ma ] Well, if the architecture is *always* going to be "parent-forked child
| 273540 [piet.haderma] Check http://sysvipc.rubyforge.org/
+ 273542 [ara.t.howard] this is, by far, the easiest approach - it addresses exactly your
+ 273543 [ news@ja .f ] Jay Levitt                |
+ 273546 [drbrain@se m] DRb will cause you to do the least amount of work.  You only need to
+ 273566 [vjoel@pa h. ] - named pipes  (man fifo)
  + 273567 [gwtmp01@ma .] Not that it would be useful but I guess that if you used
  | + 273568 [vjoel@pa h. ] I smell a ruby quiz: implement drb messaging on top of sigusr[12].
  | | 273572 [gwtmp01@ma .] Hmm.  It would be difficult.  Since signals are not reliable
  | + 273573 [garbagecat10] ...
  |   273660 [gwtmp01@ma .] I guess I should have added some smiley faces. :-)
  |   + 273661 [ news@ja .f ] I got the joke... :)
  |   + 273682 [vjoel@pa h. ] in case anyone hasn't seen that yet.
  |   + 273683 [garbagecat10] ...
  + 273760 [dan-ml@da 42] - TCPServer/TCPSocket
    + 273761 [znmeb@ce ma ] 1. You missed Rinda, a Linda derivative layered on top of DRb.
    | + 273769 [vjoel@pa h. ] And shared memory might also be nice if you don't want queueing, you
    | + 273851 [ news@ja .f ] (Putting on my fake beard)  In the old days...
    |   273863 [garbagecat10] ...
    |   273906 [znmeb@ce ma ] "If you build it, they will come." :)
    + 273777 [garbagecat10] ...
      273781 [dan-ml@da 42] Keeping in mind that this project is mainly intended as a learning
      273784 [garbagecat10] ...
      273788 [dan-ml@da 42] I'm afraid that must be a freak accident ;-)
      273804 [garbagecat10] ...
      273811 [znmeb@ce ma ] In other words, Robert Heinlein's TANSTAAFL principle holds up for this

problem writibg to temporary files
273490 [bagam_venkat] I have been facing problem while writing data to a temporary
273506 [dejan.dimic@] I have tried you code with just a string to store and it works fine.

Binaries for Libxml-ruby on windows available
273491 [pieter.bos@n] I've seen several posts on here about libxml-ruby and windows -

MS SQL Server connection via Ruby
273493 [davidslee9@g] I am running Ruby on Fedora Core 6 and I am running into problems I do
273498 [d_rems@ya oo] I was able to install freetds on ubuntu 7.04. This is my /tmp/odbc.ini

How to use hessian with custome java type?
273494 [liwenqiu@gm ] ...

data count problem in array
273509 [vidhu1232001] now i am facing problem with count, actually i need to count the data
273512 [jgabrielygal] The problem here is that * is a special character for regular
273744 [renard@nc rr] On Oct 10, 8:54 am, "Jes=FAs Gabriel y Gal=E1n" <jgabrielyga...@gmail.com>

Betfair soap problem
273515 [peter@sy te ] Basically, I can login to the service but I can't do anything else - I
273581 [nakahiro@sa ] clientstamp => clientStamp
273621 [peter@sy te ] Many thanks for answering quickly but still the same problem after
273651 [nakahiro@sa ] Oops.  I should have known it before.  You are using bundled version of
273656 [peter@sy te ] Thankyou very very much - that works! Just for completeness I just
273657 [nakahiro@sa ] Good.
273659 [peter@sy te ] Yes - once I downloaded and edited the wsdl file locally as per your
295527 [blakeage@ho ] I installed soap4r as a gem as specified on that soap4r page, and now
295535 [blakeage@ho ] require 'rubygems'

HELP - From SQL to Ruby
273522 [luciosan@gm ] How I can execute this query on Ruby?
273525 [khaines@en g] dbh = DBI.open('dbi:mysql:foo','username','password)
273924 [luciosan@gm ] <Pine.LNX.4.61.0710100922000.11180@server1.enigo.com>khaines@enigo.com

meta variable substitution
273531 [felipe.contr] I'm creating a meta script that can generate both a shell script and a
273537 [felipe.contr] Yeah, I'm generating them.
273551 [mortee.lists] Do you really want such a XML-like verbose syntax?

retain VALUE from C extension
273539 [gaspard@te i] How do I tell ruby to increment it's garbage collector if I want to
273550 [matz@ru y- a] I'm not sure what you mean by 'increment' or 'retain', but
273555 [gaspard@te i] Yes, I think this is what I was looking for. As I understand, this

Need help for my Presentation on ROR
273541 [indraneela_d] I need some documents, white papers etc for my presentation in my
273561 [nlakkakula@g] Look at InfoQ articles for ruby on rails

RubyForge migration hiccups
273544 [tom@in oe he] If you're having trouble committing to a RubyForge svn/cvs repo this
273559 [djberg96@gm ] When I ping it I see, but I still see the maintenance
273560 [cmdjackryan@] Or clean your DNS cache? On Windows it's ipconfig /flushdns (needs Admin

YAML file problem
273547 [jiorry@gm il] I hava a yaml file as application config file. I use YAML::Store to
+ 273548 [rick.denatal] Why should config.yml change?  yy is just whatever object which got
| 273549 [jiorry@gm il] We already have a config.yal
+ 273562 [vjoel@pa h. ] I don't know much about YAML::Store, but if it is a YAML version of

MaxSizeError on spreadsheet-excel olewriter
273553 [dan@ep rk ab] I am making an excel file with spreadsheet-excel Getting a
273632 [djberg96@gm ] You can't create a spreadsheet larger than 7mb currently (iirc),
273720 [dan@ep rk ab] Thanks for the info.

RubyGems Installation Problem on Solaris 10
273556 [cratervoid@y] I've installed Ruby 1.8.6 on a Solaris 10 server without a problem.
+ 273557 [drbrain@se m] Do you have a thread.so?
| 273563 [cratervoid@y] Yes, I did an ls on that directory and thread.so is there.
| + 273650 [jrich013@gm ] ...
| + 273666 [drbrain@se m] ruby -e 'require "thread"'
|   273680 [jrich013@gm ] ...
|   273701 [drbrain@se m] Then your ruby is broken (failed to compile correctly, or thread.so
|   273818 [jrich013@gm ] ...
+ 273558 [cratervoid@y] By the way I'm trying to install rubygems-0.9.4
+ 273910 [gerardo.sant] An idea: use NetBSD's pkgsrc. It has worked fine for me on Solaris 10.

[ANN] attributes-4.0.0
273570 [ara.t.howard] NAME

what does print call internally?
273575 [martindemell] irb(main):001:0> puts nil
273584 [drbrain@se m] it calls #to_s.
+ 273590 [vjoel@pa h. ] $ ruby -e 'p nil.to_s'
| + 273597 [konrad@ty er] charset="iso-8859-1"
| | 273609 [martindemell] That's quite counterintuitive, though. If true, the question becomes
| | + 273634 [dolgun@ex it] "With a couple of exceptions, every object you pass to puts and print is
| | | 273658 [drbrain@se m] Follow the calls in rb_f_print() (Kernel#print).
| | + 273832 [celtic@sa ry] Debugging is right. Otherwise, you print nothing (or "" -- who knows?).
| + 273611 [drbrain@se m] switch (TYPE(argv[i])) {
+ 273592 [dolgun@ex it] class Dog
| + 273596 [dolgun@ex it] class Dog
| | 273600 [phrogz@ma .c] If to_s returns something other than a string, Ruby shakes a naughty
| + 273613 [drbrain@se m] In IO#write, if #to_s returns nil, rb_any_to_s() gets called, which
+ 273608 [martindemell] How does print nil print "nil" then?

reading values from an excel spreadsheet
273577 [krishna_vutu] does anybody know how to open a spreadsheet and read the values in the
+ 273578 [krishna_vutu] Posted via http://www.ruby-forum.com/.
| 273579 [krishna_vutu] I actually need it for csv files not xls files...
| 273580 [ruby@gm il c] ...
+ 273599 [goal1860@ho ] xl=WIN32OLE.new('Excel.Application')

|how do you know when to put a variable between pipes?|
273582 [wetlife@gm i] question.  I see a lot of examples of a block that starts with |
+ 273587 [m_goldberg@a] In the PDF version of Pickaxe, this is explained beginning on p. 47
| 273589 [dante.regis@] ...
| 273591 [dante.regis@] ...
+ 273588 [dolgun@ex it] Whenever a method specified to the left of the block has a yield
  273607 [wetlife@gm i] Thank you so much for your help, I was having a tough time with that

how to install/configure Mysql in windows
273593 [amhidalgo@ve] What is the process to download/install/configure mysql in windows?
273595 [amhidalgo@ve] I meant how to install/configure the mysql.so library for use in ruby
273616 [dejan.dimic@] or find orhers by google search

how to ignore warning
273594 [bad_good_lio] how to ignore warning messages in ruby (when executing ruby code)
273598 [konrad@ty er] charset="utf-8"
+ 273601 [alexg@ku cr ] I agree with Konrad that you should probably fix warnings rather than
| + 273602 [bad_good_lio] thank you Alex
| + 273623 [ed.odanow@wo] Is there a possibility to ignore warnings dynamically? - I mean,
| | 273633 [lists@be tr ] =20
| | + 273643 [ed.odanow@wo] Well - it looks fine, because it's no dirty trick.
| | + 274381 [djberg96@gm ] Yuck.
| + 273624 [lists@be tr ] Or set one of the variables $-v, $-w, $VERBOSE to 'nil'.
+ 273645 [rick.denatal] Or cover your head with your towel, rubyists should ALWAYS have their
| 274399 [shaiguitar@g] likin' it :)
+ 350999 [openlampajax] Ruby will spit out warnings for white space  -  with no coding errors,