321230-336576 subjects 321603-338370

Re: Befunge (#184)
321418 [jeff@da li n] Here is my solution. It's not a revolutionary implementation, but I

Avoid trucate column at printing table
321419 [marc.pou@gm ] table = Table(%w[Page Position Domain URL Description])
321449 [b.candler@po] As a guess - because you don't actually say it yourself - this is a
321513 [marc.pou@gm ] Finally I've find the solution myself

Anyone scraping dynamic AJAX sites?
321421 [cschall@ya o] Is there anyone who has successfully found a way to scrape a dynamically
+ 321422 [8si.greg@gm ] The problem is you need a DOM-aware Javascript interpreter in your
+ 321424 [brabuhr@gm i] ...
+ 321443 [peter@ru yr ] ...
+ 321495 [kyleaschmitt] As gf pointed out, the problem is you need a full DOM and working
| 321514 [peter@ru yr ] ...
| + 321553 [kyleaschmitt] Peter
| + 321556 [flo@an er gr] Actually, firewatir and scRUBYt! are nice.
|   321721 [brabuhr@gm i] ...
|   323199 [will1@wj s. ] You could try using a virtual frame buffer if you are using Linux or
|   323227 [brabuhr@gm i] Or, start a vncserver with xstartup set to launch the scraper script.
+ 323223 [dan@da fi ni] ...

TCP Server
321426 [bakkhoz@gm i] like to
321439 [eleanor@ga e] Welcome to the colourful world of Ruby :)
321470 [hramrach@ce ] ArgumentError (ArgumentError)
321595 [eleanor@ga e] Ellie
321705 [jcmoore@pr s] By which you mean $reality ?
321707 [default@sp r] ...
321730 [eleanor@ga e] As I reserve the right to reject your reality and substitute my own

Ruby Tk and X/Y coordinates
321427 [jarek123@co ] I'm totally new to Ruby...I was wondering if anyone could help me out
+ 321429 [vjoel@pa h. ] Dig around in the tk samples dir in the ruby dsitribution.... look for
+ 321493 [nagai@ai ky ] What do you mean with the word "screen" ?
  321500 [jarek123@co ] What I'm trying to do is this:  I have an array of x,y coordinates
  321508 [nagai@ai ky ] To draw dots, please use an Oval item or a very short Line item.

Enumerable#select used to return actual values
321428 [Mike Austin ] I'm pretty sure select used to use the actual value of the called block,
+ 321432 [shortcutter@] I am pretty sure it did never.  Maybe you have a combination with
| + 321433 [robert.dober] in
| | 321434 [dblack@ru yp] res = []
| | 321435 [robert.dober] Not at all, and it is often the *fastest* solution as, unfortunately,
| | 321447 [james@gr yp ] My opinion is that if inject() is really the biggest time sync in your
| | + 321448 [james@gr yp ] Well, I meant big trouble if you're still looking for optimizations.
| | + 321476 [robert.dober] de,
| |   321480 [james@gr yp ] You may have a point there.  I'm pretty sure Merb has done similar
| + 321437 [dblack@ru yp] (0..10).each_with_object([]) {|e,a| a << (e * e) if e > 5 }
|   321479 [matz@ru y- a] #each_with_object is an interesting concept.  Maybe we can add it to
|   + 321482 [transfire@gm] I take it that #each_with_object returns the accumulator, ie.
|   | 321484 [matz@ru y- a] Probably.
|   + 321485 [robert.dober] Maybe the difficulty to find a name points to a problem...
|   | 321498 [Mike Austin ] What about just "each_with()"?
|   | 321507 [florian.assm] What about Enumerable.into(something) ...
|   + 321509 [dblack@ru yp] But it's in Enumerable already, in 1.9.
|     321510 [matz@ru y- a] Ah, actually I am going to check it in tonight using my time machine. ;-)
|     322122 [nobu@ru y- a] It's added by knu at r18864.
+ 321440 [transfire@gm] On Nov 29, 10:39=A0pm, Mike Austin <"mike[nospam]"@mike-austin.com>
| 321450 [transfire@gm] is
+ 321612 [botp@de mo t] # (1..10).select { |a| a * a if a > 5 }
| + 321649 [dblack@ru yp] ...
| + 321654 [Mike Austin ] that's... the idea.
+ 321906 [mark@th ma z] On Nov 29, 10:46=A0pm, Mike Austin <"mike[nospam]"@mike-austin.com>
  321912 [transfire@gm] is
  321914 [matz@ru y- a] I don't deny the existence of use case of such method (although I
  + 321916 [robert.dober] Hmmm
  + 321919 [marcelo.maga] #transform ?
  + 321921 [transfire@gm] Why do you say? Is not "compact conditionally on result of block" a
  | + 321926 [robert.dober] Indeed this is the behavior I had expected from delete and having a
  | | 321930 [transfire@gm] Almost. There's an important distinction. #reject is an Enumerable
  | | 321938 [robert.dober] Ah I did not know.
  | + 321934 [matz@ru y- a] As far as I understand, the word compact means removing empty spaces,
  + 321964 [mark@th ma z] =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 matz.
    322105 [Mike Austin ] I know someone brought it up already, but why not "collect_if"?  It's

[ANN] Bacon 1.1, a small RSpec clone
321436 [chneukirchen] Today I'm proud to release Bacon 1.1.
+ 321438 [robert.dober] .org/releases/gems
| 321444 [chneukirchen] Indeed, it's just one file.
+ 321522 [pit.capitain] Christian, could you talk a little bit about the relation between

Does A_UNDERLINE work in Ncurses-ruby ?
321445 [sentinel.200] Has anyone used this attribute while printing to a window ?
321672 [sentinel.200] The problem lies with the terminal named "screen". It underlines when

ANN: rake-compiler 0.2.1
321446 [luislavena@g] I'll like to introduce you rake-compiler gem version 0.2.1
322121 [transfire@gm] I look forward to trying this out. Thanks Luis!

Re: Bacon 1.1, a small RSpec clone
321451 [ymendel@po o] On Nov 30, 4:29=A0am, Christian Neukirchen <chneukirc...@gmail.com>

Aaron Bedra@Relevance Inc fraudulently claiming ownership of BSD licensed code -- how to protect?
321452 [cilibrar@gm ] I have been programming open source for about fifteen years and have
+ 321455 [marcelo.maga] Did you contact him or his company?  If your code is GPLed, you might
+ 321456 [cilibrar@gm ] Thank you for pointing out that at least there was mention of Emil in
| 321459 [aaron.bedra@] ...
+ 321457 [lojicdotcom@] "I tried emailing the people that were in charge of the project

Some benchmarks with MinGW, JRuby, MSVC...
321453 [joaopedrosa@] So, I have managed to build several different versions of Ruby to
+ 321478 [post@tu bc o] According to my own tests, "Thin" should be better than your current
| 321598 [post@tu bc o] I notice that you use the best of 5 runs to report numbers, which I
| 321600 [post@tu bc o] Oops! Forgot to paste the codes I used for TudbcJRubyServlet
+ 321483 [charles.nutt] I'd love to figure out what makes mongrel slow for us, when all other
+ 321575 [ezmobius@gm ] Benchmarking ruby on windows is fairly useless. MRI 1.8.* is known to
  321580 [semmons99@gm] ...

Help me understand how this block works?
321454 [ruby-forum@g] I'm working through a tutorial and Ive come across a line of code that I
+ 321458 [einarmagnus@] Google "ruby iterators tutorial" and try typing
| 321461 [matt@ti bi s] Big-iMac-Attack:~ mattneub$ ri Enumerable#inject
+ 321460 [matt@ti bi s] Scroll down to "inject" and look at the third format. The "0" from the
| 321465 [ruby-forum@g] Thank you, that explains it very well for me.  Another quick question.
| + 321468 [dblack@ru yp] If the collection you're iterating through has pairs of values, you
| + 321469 [caduceass@gm] You apply #inject on an Enumerable object.  Do you mean that you want
|   321486 [ruby-forum@g] Not trying to accomplish anything, just trying to understand how it
+ 321464 [caduceass@gm] It populates memo with 0 at first and thereafter with the value that
+ 321512 [b.candler@po] There was a recent thread which may provide some useful examples: around
  321526 [ruby-forum@g] Excellent, that answers it perfectly thank you.

How to reset constants in tests?
321463 [bjohnson@bi ] I am writing tests for configuration options that make class level
321466 [dblack@ru yp] The first thing that comes to mind is something like this (untested,

[ANN] fail-fast 1.0.0 Released
321467 [avdi@av i. r] fail-fast version 1.0.0 has been released!

[QUIZ] Re: Befunge (#184)
321472 [adam.oddfell] Here's my Befunge interpreter, my first submission for a Ruby-Quiz. I'm

Will Tk still be standard in 1.9?
321481 [davekapp@gm ] I realize there's a lot of GUI options when using Ruby, and there's also
321517 [b.candler@po] Posted via http://www.ruby-forum.com/.

Where can I download ruby rdoc?
321487 [youhaodeyi@g] I downloaded and installed ruby in a Windows XP system but I couldn't
321503 [keeperotphon] ...
321520 [youhaodeyi@g] Is there a ruby core doc? I only found the gems, rakes docs.

new here on ruby-talk
321488 [rich.japh@gm] community here.
+ 321490 [mguterl@gm i] This mailing list is fine for any level of rubyist.  Just be sure to
| 321496 [rich.japh@gm] will do.
+ 321497 [phlip2005@gm] All we ask is you try every question with Google first. You will find
  321502 [james.britt@] Well, no and yes.   Certain topics have little about them that will

Form Controls for User interface in a Database Application
321489 [rr3800@gm il] Is there an IDE for Ruby where i can drag n drop Grid Controls, COmbo
+ 321491 [mguterl@gm i] You could use JRuby, Netbeans, and Matisse.
| 321494 [rr3800@gm il] ...
+ 321504 [kbloom@gm il] You could use qt4-qtruby and the qt4 designer.
  321515 [rr3800@gm il] ...

[ANN] amalgalite 0.5.1 Released
321505 [jeremy@hi eg] amalgalite version 0.5.1 has been released.

really beginner question
321506 [rocksonchan@] question.
+ 321516 [1337indi@gm ] In response to a free editor program, I use SciTE, I believe there is an
| 321554 [acooper@pr t] an=20
| 321560 [rocksonchan@] WOW~~ thanks for all the advices and suggestion.
+ 321518 [sandor.szuec] If you use TextEdit then you should change the preferences so that
| 321535 [toastkid.wil] a simple text editor and the command line is better.
| + 321545 [caduceass@gm] I don't use a Mac, but amen to that.  My experience with IDE's has
| + 321549 [james.britt@] I know  mac-owning rubyists who use Netbeans for it's auto-completion
+ 321551 [lloyd@2l ve ] Personally, I recommend that you go to http://www.sun.com/ and get
| 321552 [toastkid.wil] Actually, when i did used to use an IDE i did use netbeans, which has
+ 325031 [wkromani@gm ] ...

[ANN] Fukuoka Ruby Award
321511 [matz@ru y- a] The Fukuoka prefecture conducts Fukuoka Ruby Award.  The winner will

Control Structures
321519 [1337indi@gm ] G'day all, I'm new to Ruby, been studying Software Engineering at
+ 321523 [severus@po t] monkey = []
| + 321524 [jorrel@gm il] a.to_i.times { monkey.push((rand*5+1).to_i)
| + 321525 [dbw@ab r. c.] What would be the quickest way of doing it? (in terms of time and =
|   321541 [severus@po t] The following version doesn't use Array#sort (which returns sorted copy of Array; I haven't looked at Ruby source which sorting algorithm is used, you can look yourself if you want), but I presume that you don't need complete set of a numbers in every attempt. However it isn't hard to make another version without this presumption.
|   321548 [b.candler@po] Like many languages, there are lots of ways to do things. Using a block
|   321566 [robert.dober] I am not sure if you want this optimization
|   321571 [b.candler@po] Whilst this demonstrates Dober's Law that every program can be written
|   321573 [robert.dober] You know I have to jump at any opportunity to present inject when
|   322072 [1337indi@gm ] Thanks to everyone for the help, I manage to get it working, not at all
+ 321529 [gdprasad@gm ] ...
  321531 [gdprasad@gm ] ...

Using File:Stat.mode method to find file permissions in Unix
321521 [vikram.iiita] I am trying to find the permissions on a file, using mode method of
321527 [TimHunter@nc] Permissions are typically specified as octal numbers. 16895 is decimal.
321528 [vikram.iiita] Oh Yes ! Thanks a lot.. :-)

How do you find an item that satisfies multiple conditions?
321530 [small.busine] @items.find {|item| item.product == product }
+ 321532 [chad@ch df w] elements for which the block returns boolean true.  In this case, your
| + 321534 [small.busine] Chad and Stefano! Thank you!! =)
| + 321567 [robert.dober] I am afraid that you confused Enumerable#find with Enumerable#select
+ 321533 [stefano.croc] @items.find{|item| item.product == product && item.red == red && item.blue == blue}

ApressDailyDeal - Practical Ruby Projects
321536 [jeffrey.scho] ...
+ 321543 [pat.eyler@gm] if you're thinking about the book, feel free to take a look.  (The links to
+ 321550 [jontyjont@bt] Many thanks for the heads up!

[ANN] Ruby 1.9.1 Preview 2 Released
321537 [yugui@yu ui ] Ruby 1.9.1 Preview 2 has been released.

Explanation on some code
321538 [registraties] Today i looked at ruby for the first time.
+ 321539 [robert.dober] It is a hash (literally specified at the RHS of the equal sign)
| 321569 [sepp2k@go gl] You call it "key_value_pair*s*", but don't allow more than one pair. I think
| 321570 [robert.dober] U know, exercise left to the reader ;)
+ 321540 [fekete@me ko] It's a HASH - code structure similar to array where you use as index string
+ 321542 [registraties] Thanks for the quick replies. I will figure it out now.

Load C extension in Mac OS X linked a a dylib
321544 [elias.athana] I noticed that Ruby is refusing to load an extension in Mac OS X
325374 [nobu@ru y- a] What differences between bundle and dylib?
325409 [luc@ho k- on] On OS X a dylib is a "normal" shared library usually brought to life

Another Ruby Book (and interview)
321546 [pat.eyler@gm] Most ruby-talk readers probably know that a Ruby edition
321922 [perrin@ap th] w.html
321927 [pat.eyler@gm] The workbook is meant to be a tool to guide a practitioner through
321980 [perrin@ap th] Thanks for clarifying.  That wasn't even slightly clear from the
321982 [pat.eyler@gm] I'll correct that when I review the book (once it's out).  Thanks for

1.9 onwards (planned) runtime changes
321547 [rainerfrey@w] as I could not find any reference in recent postings, please allow for this

Re: turn 0.4.0
321555 [djberg96@gm ] till

Multi-Index Containers
321557 [avdi@av i. r] Does anyone know of a multi-index container library for Ruby?  I just
+ 321559 [ara.t.howard] gem install rbtree
| 321561 [avdi@av i. r] I'm not sure I understand how a Red/Black Tree covers indexing by
+ 321596 [shortcutter@] I haven't seen it so far.  Basically this would mimic what a relational

HTTP Proxy problem in SOAP based webservice
321558 [keith2koool@] While accessing my application through a proxy bypassed system, the

[ANN] crate 0.1.1 Released
321562 [jeremy@hi eg] I'm pleased to announce that Crate, the project I spoke on at RubyConf
+ 321576 [ezmobius@gm ] This project is pure awesome, that is all.
| 321586 [jeremy@hi eg] Thank you Ezra.  I happen to think so too :-).
+ 321577 [avdi@av i. r] Stupid question: what's the advantage of using a SQLite DB over a
  321584 [jeremy@hi eg] Stupid answer: I really have no idea.  I didn't even think about it.

question about the system method
321564 [zhujie2003in] I want to use system method to run a background process, like
321565 [avdi@av i. r] The basic answer is to use IO.popen() - see
321609 [zhujie2003in] IO.popen() works well.

Regular Expressions
321574 [mmc_collins@] Just a question about regualar expression in Ruby. Is there a way to
+ 321578 [yaserbuntu@g] ...
| 321588 [mmc_collins@] thanks everyone!
+ 321579 [james@gr yp ] Sure.
+ 321581 [kyleaschmitt] I just wanted to mention another way of combining regexes that may
| 321582 [kyleaschmitt] Scratch that, not thinking clearly!  This is to match startswith OR
| + 321585 [yaserbuntu@g] ...
| + 321587 [mmc_collins@] Alright. thanks for the tip. I was just thinking...what is the
| + 321591 [joe@ta kh us] Interesting that there is a union function but no intersection function.=
|   + 321592 [Rob@Ag le on] How would you even define a regexp (re) that matched only when both of =20=
|   | + 321597 [joe@ta kh us] Not sure I understand.  Are you arguing that an intersection cannot =20
|   | | 321599 [Rob@Ag le on] <kyleaschmitt@gmail.com=20
|   | + 321608 [kbloom@gm il] It's very well defined if you're talking about an underlying
|   + 321593 [sepp2k@go gl] for=20
+ 321860 [richard.conr] I just simply have to pimp http://www.rubular.com/

Object private methods
321589 [keepitsimple] Consider the following,
321590 [robert.dober] Does it? Any pointers? Well it is clearly incorrect.

ruby-prof on freebsd
321594 [ moo@co .o g] $ ruby-prof --mode memory test.rb

Adventures in Optimization... or why CONST frozen is Good
321601 [john.carter@] ...or when a language design level optimization is a pessimization.
+ 321602 [ara.t.howard] thanks john.   interesting.
+ 321667 [b.candler@po] Yes, that's the "right" solution with Ruby today, and you'll see this
  321675 [shortcutter@] Completely agree, this comes as no surprise. Actually, this is an
  321676 [fred@la av .] 16:41 grappa:~> qri 'Hash#[]='