10063-11543 subjects 10443-11076

configure shebang paths for apache cgi?
10245 [chrismo@ho e] I've got a ruby cgi script that I'd like to distribute (Linux & Windows).
10254 [frankm@ba ar] #!/usr/bin/env ruby
10276 [jim@fr ez .o] For versions where you cannot associate a file type (ie, . followed by a
10277 [ben_tilly@ho] It is actually shipped on 5.6.  The tricks used is that Perl
10285 [ChrisM@SN LL] I found on my 95 box, if I just do
10287 [dgjs@ac .o g] For that to work, you need 'ruby' in your $PATH.  Try "which ruby".
10290 [ChrisM@SN LL] Thanks for the info! I tried 'which' and it worked -- so I tried the shebang

Miniturising libraries on Linux
10250 [jfenn@uk in ] I have been thinking about how to go about putting ruby in a limited resource enviroment (a PDA) and have written a little hack to pull the libraries out of a tar.gz file when needed. It seems to work but I am posting it here because I am interested to hear of any potential problems people might foresee with it, ways it could be more efficient or any other space saving ideas. I am a ruby newbie so please have mercy!
10251 [jfenn@uk in ] Sorry, I didn't mean to post that again :-s Bug in email prog

stackless ruby
10261 [jonas.bulow@] I don't now too much about the internals of ruby but would it make sense
+ 10262 [decoux@mo lo] See [ruby-talk:9602]
+ 10268 [matz@ze ab t] It's totally different.  But some (including me) working on a new

Telnet program in ruby?
10271 [hgs@dm .a .u] Given the existence of Tk widget demos in Ruby, and the net/telnet module,
+ 10275 [ben_tilly@ho] Glancing at the FAQ it looks like its xterm emulation
| 10280 [hgs@dm .a .u] Only because I could not find a wheel that was free, and also as an
+ 10301 [tarod@ho e. ] client
  + 10302 [crouton@we t] TeraTerm is another good telnet/ssh app for Windoze.
  + 10376 [hgs@dm .a .u] Thank you to those who pointed me to PuTTY.  This seems to have the capabilities
    10397 [tarod@ho e. ] capabilities
    10504 [hgs@dm .a .u] I will look into this. Thank you.  I think I will persue sun about this

Vector questions
10281 [jim@fr ez .o] I am using the Vector class. I am using Vector instead of Array because I
10282 [dblack@ca dl] #map is available, though not having each does seem asymmetrical
10284 [jim@fr ez .o] Would adding #each be as simple as adding the following to matrix.rb
10291 [dblack@ca dl] That 0.upto(size - 1) idiom, as used in matrix.rb, keeps the two

telnet and su?
10283 [sp00fD@ya oo] I'm using net/telnet to open a session and run some commands, but I'd
10288 [sp00fD@ya oo] nevermind, i got it, thanks anyway

Ideas for Ruby (A Python/Perl phrasebook)
10289 [schneik@us i] # A Python/Perl phrasebook

Ruby cgi's in IIS
10294 [tarod@ho e. ] Has anyone figured out how to make ruby cgi's run under NT/IIS?  Apache
10303 [erne@po er a] In the management console, right click on the directory where the Ruby
+ 10340 [tarod@ho e. ] Thanks.  Somehow I find IIS's gui more confusing than Apache's conf
+ 10348 [erne@po er a] There is a way to get fast CGI under windows, by using another server other
  10358 [tarod@ho e. ] Thank you.  I'll be sure to check out that script.  However, if I were to

read from standard input ....
10295 [jens@ir -n t] I never managed it to read something from standard
10296 [wmwilson1@go] STDIN.gets or even STDIN.gets.chomp (or $stdin, or whatever) should do it for ya
10297 [jens@ir -n t] Great. Thanks...

Local directory search "server" script
10298 [schuerig@ac ] Now that my X server is working again I've put together the first
10299 [wmwilson1@go] ==Possible stupidity disclaimer ;)
10306 [schuerig@ac ] It's not meant to be clever, it's just the first thing that occurred to
10307 [wmwilson1@go] I just realized that it's possible that you/someone may have thought that the "stupidity disclaimer" was referring to my opinion of what you were doing.  It wasn't, it was referring to me and my possibly stupid question.  I hope you understood that, sorry if you didn't.  I really need to think before I type...
+ 10308 [ms@ia ta e. ] Dunno about that.  This forum has always seemed to have an uncommonly
| 10318 [elderburn@mi] What's wrong with us? Are we some kind of rebel cult going against the flow of
+ 10313 [schuerig@ac ] No, I didn't even think of this. And anyway, I'm a Ruby Nuby and
  10316 [wmwilson1@go] I wasn't advocating the use of globals (I'm assuming when you say global, you mean $var), only trying to learn what using instance variables brings to the table when not used in class instances.

mmap module?
10300 [joe@vp p. et] Has anyone developed an mmap module for ruby?

critique this program pleaase
10309 [sp00fD@ya oo] I was wondering if anyone could take a gander at this program and tell
10310 [chadfowler@y] Is progname in scope here?
10315 [sp00fD@ya oo] no, no it's not.  I pass it in as a parameter now.  Thanks for the

More C API examples?
10311 [lists.ruby-t] I was wondering if someone has examples of defining and then
+ 10312 [decoux@mo lo] Well, it's mentioned in README.EXT
+ 10314 [matz@ze ab t] Don't use NEWOBJ() in your extension, since it requires own unique
  10541 [lists.ruby-t] Sure enough, seems to be working nicely so far.  Just took a while

TCPServer - bug in documentation ?
10317 [neumann@s- i] It seems to be, that there's either an bug in TCPServer, or
10319 [Dave@Pr gm t] I'd always assume the latter ;-)
10322 [dgjs@ac .o g] I get the behavior reported by Michael Neumann, because on my machine
10323 [neumann@s- i] My system is NetBSD 1.5 with IPv6 enabled!

Nested modules and classes?
10320 [gnhurst@hu s] I have not yet seen an answer to this question, and
+ 10372 [matz@ze ab t] It's basically for name space control.
+ 10373 [  zak@al .c ] Nested modules are definitely useful as nested namespaces.
  10374 [ben_tilly@ho] Cool, Ruby does this?  I have a good use for using nested
  10405 [wys@he bl ng] STRATEGY PATTERN?
  10415 [ben_tilly@ho] No.

OT: Smoking (was Re: ANN: Slide show available)
10325 [sent@qu li y] I was pleasantly surprised to find that
+ 10326 [joe@vp p. et] It sure does.  And I also think the law is a bad one.  I won't
| 10332 [ben_tilly@ho] This reminds me of a funny story I saw in the NY Times.
| 10334 [wmwilson1@go] Don't forget us gigolo's! ;)
| + 10335 [joe@vp p. et] Ya, my wife doesn't allow me to smoke inside, so I have
| | 10342 [decoux@mo lo] There is a *BIG* problem actually because I've found something *VERY STUPID*
| + 10350 [matz@ze ab t] I'm sorry if you felt offended.  Although I hate smoke but I don't
|   10352 [Dave@Pr gm t] And quite a few smokers hack (but not necessarily code)  ;-)
|   10353 [wmwilson01@h] No, not at all.  I'm not real happy when I've got people smoking around me
|   10354 [mitch@ve ux ] It's a nasty habit, I hate to be around second-hand smoke as much as anyone
+ 10402 [matz@ze ab t] Do you guys think it's possible to us to have BOF or something, if I
  10416 [matt@se ge n] I think that's a good idea. I'll ask Nat (the organiser) if we need to make
  10475 [sent@qu li y] I can't commit right now, but would really hope

Another OT smoking story Re:
10327 [dgjs@ac .o g] A few years ago, some Frenchman (whose name I can't recall) rowed solo

Multi-dimensional Array
10328 [jasowong@my ] Beginning programmer (and beginning Ruby programmer) here... First off,
+ 10329 [wmwilson1@go] Welcome!
| 10333 [sent@qu li y] Strong agreement.
+ 10359 [matju@ca .o ] It could be. You may take a look at the NArray library for that. However
| 10368 [skeeler@si i] Eventually, you'll need to make queries like "what objects are at the
+ 10383 [jfn@en er ct] I won't touch questions 'a' and 'c' because others have.  But Ruby makes

Efficiency Check
10330 [jasowong@my ] Below is a directory wide (or file wide, depending on your preference)
10339 [phasis@ch nn] How about this?
10345 [wmwilson01@h] I'm curious as to why the BEGIN block is used here?  Also, seeing as there's
10363 [phasis@ha an] there's

Templating System
10331 [jasowong@my ] Is there a templating system, ala WebMacro (http://www.webmacro.org)
10338 [avi@be a4 co] Check out http://beta4.com/iowa

ObjectSpace.each_object & terminated objects
10336 [Dave@Pr gm t] ObjectSpace.each_object {|o| o.id}
10347 [matz@ze ab t] It's a bug caused by incomplete back port from 1.7, here's the patch.

Re: ANN: Slide show available (neoteny?)
10341 [ptkwt@sh ll ] And I thought the point was that he looked younger because he doesn't
10349 [ben_tilly@ho] Based on my experience, I would guess that race

[ann] Rinn
10344 [MAP2303@ma l] I'm glad to introduce first runnable version of Rinn.

wconio for ruby
10356 [snowzone@ho ] if someone ported this small python  extension to ruby, my life would be


Bibtex entry for pickaxe book?
10371 [feldt@ce ch ] Sorry, I'm being lazy: Anyone got a bibtex entry for the pickaxe book?

Problems creating persistent objects
10375 [danny@so er ] module Storage
+ 10378 [decoux@mo lo] WARNING wait confirmation from matz
+ 10389 [avi@be a4 co] How about something like
+ 10407 [matz@ze ab t] The closure created by `proc{store}' contains the reference to self,
+ 10430 [danny@so er ] Thanks for the responses. they were very helpful. there follows an amended

10379 [mitch@ve ux ] Is anyone else developing or maintaining the PostgreSQL module for Ruby?
10408 [matz@ze ab t] Wait bit longer.  His machine crashed last week.

ArrayMixin 0.3
10380 [matju@ca .o ] ArrayMixin 0.3

New way to learn Ruby?
10382 [jqcordova@my] I've spent the last couple of years building well-known e-commerce
10384 [harryo@zi wo] This is somewhat of an understatement.  As far as I can tell, there's

Structured text matching?
10385 [schuerig@ac ] I'm trying to match and extract pieces from structured text in a similar
+ 10387 [0317025435@t] # Sample line from a HTML file
| + 10388 [ben_tilly@ho] I don't know what tools exist for this, but I am in
| | 10391 [schuerig@ac ] [ad hoc parsing]
| + 10390 [schuerig@ac ] That's exactly the restriction I'd like to avoid...
|   10394 [Dave@Pr gm t] str = File.open("x.html") {|f| f.read}
|   + 10395 [erne@po er a] But Dave no one will say "You look Marvellous!"
|   + 10404 [wys@he bl ng] THE "PRAGMATIC" WAY ;-)
|   + 10441 [schuerig@ac ] The best solution would be to have someone else write the parser... ;-)
+ 10393 [joe@vp p. et] I don't know of a ruby option, but perl has a really nice

Ruby/Tk, what am I doing wrong...
10386 [noel.rappin@] Now I'm diving into Ruby/Tk and I have some newbie type questions...
10398 [harryo@zi wo] I THINK the problem with this one is that it should be

Stealing some Perl infrastructure
10392 [ptkwt@sh ll ] I was looking at some Win32 perl modules on CPAN recently - specifically,
10484 [schneik@us i] # I was looking at some Win32 perl modules on CPAN recently -

Re: [OT now] Re: Structured text matching?
10396 [mike@st k. o] Damian Conway does a lot of impressive stuff and useful stuff in perl,

Ruby users in Sydney?
10399 [harryo@zi wo] I was just wondering how many of the people who read this newgroup are
+ 10400 [Robert.Dawso] You got the right Country for me :).
| + 10401 [ben_tilly@ho] Well if we are going to put out general requests, I am in
| + 10403 [steve@de f. ] Adelaide, Australia, here. :)
|   + 10406 [tarod@ho e. ] I think there must be a limit to the number of Ruby programmers allowed per
|   | 10409 [   xm@w3 .r ] Rostov-on-Don, Rostov region, Russian Federation reporting ;) (not from USA
|   + 10414 [progress@as ] Canberra, here 8^)
|   + 10431 [mfp@st de ts] I'm from Melbourne, Australia, and I'm yet to meet another Ruby user, :(
|     10448 [schneik@us i] # >
|     + 10449 [gilc@sh pl o] I'm in NY, NY, too. :)
|     + 10450 [mike@st k. o] Count me in the Austinites (until I move)
|     + 10458 [hipster@xs a] I'm in The Netherlands, any more Dutch Rubicians present?
|       10607 [danny@fr uk ] Over here! Well, I'm learning it anyway <:)
+ 10463 [dnaseby@af i] I'm a Ruby user in Sydney (and a list lurker), and I'm quite open to the
  10464 [sfekas@ya oo] I think we've hit on a need for the community here.
  + 10465 [wmwilson01@h] I'm in Northern Virginia, USA, myself.  Couldn't be far from you.  I would
  + 10466 [Dave@Pr gm t] Would a wiki page do for now?
    10499 [schneik@us i] #
    10544 [sol123@ms .c] ...
    10545 [ben_tilly@ho] [etc]

Ruby User Survey (repeat announcement)
10410 [schneiker@ju] If you are new to Ruby (or haven't previously taken the Ruby User

The Ruby Way (to post replies)
10411 [schneiker@ju] As a member of the "Big 8" newsgroups, "The Ruby Way" (of posting) is to

RUBY NEWSGROUP FAQ -- Welcome to comp.lang.ruby!  (Revised 2000-12-28)
10412 [schneiker@ju] RUBY NEWSGROUP FAQ -- Welcome to comp.lang.ruby!  (Revised 2000-12-28)

RE: Welcome to our (ruby-talk ML) You are added automatically
10413 [adam.abrams@] ...

Recall Regexp options?
10417 [ben_tilly@ho] Does this make sense to anyone?
10427 [matz@ze ab t] No.  I should have compare all option flags for equal test.
10435 [ben_tilly@ho] Thank you, and if you make the options available as an
10446 [matz@ze ab t] I will do this too.  Do you think Regexp#options is a good name for
10451 [schneik@us i] # >|PPS Coming from Perl I find it disconcerting to see
10452 [ben_tilly@ho] new_re = Regexp.new(re.source, re.options, re.kcode.to_s)
10453 [Dave@Pr gm t] Although it would also be nice to have
10492 [schneik@us i] # In message "[ruby-talk:10417] Recall Regexp options?"
10496 [decoux@mo lo] Probably I'm wrong but ruby /m is perl /s
10514 [ben_tilly@ho] I am trying to figure out why you would want to

Installing on Mandrake 7.1
10419 [peterhi@my d] I have the 1.6.2 tarball and I've unpacked it to /root/x. I've then run
10437 [matju@ca .o ] The point of doing that is so you can differentiate easily what you
+ 10574 [peterhi@my d] note
+ 10575 [decoux@mo lo] Yes, have_header() call cpp and cpp look at the dependencies.

Preemptive scheduling?
10420 [wys@he bl ng] def recursion(n)
+ 10428 [matz@ze ab t] What are you expecting?  On my box th2 seemed to have killed th1.
| 10480 [wys@he bl ng] <<SNIP>>
| 10483 [matz@ze ab t] Hmm, using the following code, th1 was killed after 10 recursions.
| 10505 [wys@he bl ng] <<SNIP>>
| 10511 [matz@ze ab t] Maybe.  As Mathieu mentioned in [ruby-talk:10439], you have to be
+ 10439 [matju@ca .o ] y = 1
  10489 [wys@he bl ng] <<SNIP>>
  10490 [adam.abrams@] ...
  10493 [schneik@us i] # Do not use mere numbers for conditionals.  It may cause surprising
  10497 [matz@ze ab t] Yes.  1.7 reports this.  The latest does even without -w.

ruby highlighting for enscript
10421 [wmwilson01@h] Anyone use enscript?  If so, I've created a ruby syntax highlighting
10422 [feldt@ce ch ] I'd be interested but I suggest you submit to RAA. Easier for everyone to
10423 [wmwilson01@h] anyone have any advice as to what category this would fit in?  Also, seeing
10470 [sent@qu li y] I don't use enscript, but it seems that other
10491 [schneik@us i] # >From: Robert Feldt <feldt@ce.chalmers.se>

generic method
10424 [decoux@mo lo] I've a problem with generic methods.
+ 10425 [feldt@ce ch ] Is this a brand new addition to Ruby (generic/overlaoded methods)? Doesn't
| 10429 [decoux@mo lo] No, it's my toy :-)
| 10432 [feldt@ce ch ] Ok, always on the leading edge... ;-)
| 10433 [decoux@mo lo] Search in the superclass. Actually this is search_method() which is
+ 10445 [matz@ze ab t] Tell me, have you implemented this already?
+ 10476 [decoux@mo lo] Yes, but not yet finished.
  10478 [matz@ze ab t] Wow, it's great.  I should have took chance to visit you while I was in

book review?
10426 [wmwilson01@h] Instead of letting it fall through the cracks on the assumption that I
+ 10436 [ben_tilly@ho] I believe a book has been sent.  I just didn't want to
| 10438 [wmwilson01@h] Thank you very much.  By all means, I don't want to rush him.  I just wanted
+ 10440 [Dave@Pr gm t] The book arrived yesterday, and is currently on the top of his
  10442 [wmwilson01@h] damn, too late.  What he heck am I suppose to do with this kid now!? ;)
  10472 [hal9000@hy e] LOL
  10539 [andy@to ls e] That's the ticket, start teaching good habits young.
  + 10540 [mitch@ve ux ] Andy (and Dave!), Programming Ruby is a damn good book... It proudly sits on
  | 10588 [andy@to ls e] I never get tired of saying "you're welcome", even after ten billion times :-)
  | + 10589 [sent@qu li y] I've heard this many times and still don't buy
  | | 10593 [ms@ia ta e. ] I've had this discussion with a good friend a number of times, and we
  | + 10591 [mvincent@ve ] Absolutely, I've thanks Matz a few times on-list for a hell of a
  + 10547 [lists.ruby-t] Actually, I was wondering the other day whether Ruby might make a
    10550 [sent@qu li y] If I were going to teach someone programming, I
    + 10553 [0317025435@t] Hey, don't spoil them from start! It's good for them to be able to use a
    | 10572 [ben_tilly@ho] A lot of the following proposal for teaching Python to
    + 10573 [elderburn@mi] Hmmmm....that might be an advantage. :-)

Serialization/persistence/marshalling to/from XML?
10434 [kentda@st d.] Is there a library or framework for serializing a hierarchy of Ruby
10444 [neumann@s- i] Have a look at XML-RPC for something SOAP-like which is neither cast in iron, nor language-tied.
10604 [kentda@st d.] Thanx for the nudge I needed to look deeper at XML-RPC. But, alas, it's
10616 [nahi@ke na t] Though I've never use it, Fukushima-san's XMarshal might