169501-171217

169314-172185 subjects 169676-175646

^ Re: Amrita2 1.9.6
169501 [gsinclair gm] Great.  Any chance you could release Amrita as a gem?
169581 [takunakajima] I have uploaded gem of Amrita2 to rubyforge. So, you can install

^ interesting book sales news
169505 [pat.eyler gm] Ruby books are up over 1500% over last year, while Python books

^ ruby pipe with arguments error
169506 [capitain gma] i am newbie of ruby , but i met a strange problem
169529 [nobuyoshi.na] ARGF doesn't equal STDIN.

^ Ruby + Lotus Domino oh my!
169509 [kevin.jackso] Does anyone have any experience interfacing ruby to Notes/Domino?  I
+ 169733 [wilsonb gmai] If you can run Ruby on the same box as Domino, you can do this.  This
+ 171214 [meta pobox.c] If there's a Domino server involved (i.e. it's not just a database on a
  171216 [sam.dela.cru] folder from my mailfile.  You can easily modify this to get data from any
  171217 [sam.dela.cru] Sorry, the tab spaces were kind of messed-up, here's the same code with

^ is this a good way to find anagrams?
169512 [wrong socal.] it seems to me, with computers these days, this should finish
+ 169528 [mrkode gmail] umm... what's the dictionary for?
+ 169540 [batkins57 gm] One thing you could try is inverting your algorithm.  My dict/words
| + 169547 [batkins57 gm] I went ahead and implemented my own suggestions, and just to give you
| | 170066 [djberg96 gma] I think there's an algorithm for finding anagrams using libgmp, for
| + 169552 [martindemell] Even faster - sort the list of permutations, then do an incremental
+ 169544 [m.fellinger ] charset="iso-8859-1"
| 169835 [chneukirchen] Better use #find_all, no?
+ 169845 [ruby.brian g] if you want to find lots of anagrams against the same database it
  169848 [ruby.brian g] hash =

^ SF Beer & Dim Sum SIG (12/28) - !change of venue!
169514 [rdm cfcl.com] It turns out that the Long Island Chinese Restaurant has (a) moved

^ About class methods
169516 [hankgong gma] class methods and instance methods.
+ 169519 [logancapaldo] class methods are (more or less) the same thing as static methods in C
+ 169522 [james_b neur] p Array.class  # Class
| 169524 [transfire gm] Actually, they are ad hoc. ;-)
| 169587 [transfire gm] Sorry Hank, if you are unware of what were talking about in these last
| + 169658 [hankgong gma] I carefully read two articles about classmethods and singleton concept.
| | 169669 [dblack wobbl] Basically an object's singleton class is a class created ad hoc, and
| | + 169709 [transfire gm] Interesting. Perhaps we've met halfway then. 'Ad hoc' is an excellent
| | | 169721 [zjll9 imail.] What did you guys think about using simpleton to refer to these
| | | 169743 [gwtmp01 mac.] On Dec 8, 2005, at 3:45 PM, jonathan <zjll9@imail.etsu.edu>
| | | 169806 [zjll9 imail.] been called a singleton but, it has no methods at all (neither class nor
| | | 169810 [zjll9 imail.] My understanding of 'singleton' methods or 'ad hoc' methods or
| | | 169861 [transfire gm] J,
| | | 170016 [zjll9 imail.] Well, actually, I think you do it the same way you would in C++, i.e.,
| | | 170019 [zjll9 imail.] T,
| | | 170025 [transfire gm] Well, I think its basically because Matz used the class nothing more
| | | + 170027 [dblack wobbl] The latter, yes, from what Matz has said (no convenience method
| | | | 170160 [transfire gm] I tend to agree with you. While on the surface it may seem simpler
| | | + 170035 [zjll9 imail.] Hmm.. Ok.  But, with Ruby, you can still dynamically create subclasses
| | |   + 170053 [dblack wobbl] The starting-point of the whole thing is the principle that objects
| | |   | 170106 [zjll9 imail.] Hmm.  Ok, so there really is no singleton class for Myclass?  In other
| | |   | + 170112 [gwtmp01 mac.] In Ruby, a class *is* an instance.  Specifically, a class is an instance
| | |   | | 170116 [zjll9 imail.] Oops.  It should have been #{some_class}.  The whole point of that was
| | |   | | 170118 [zjll9 imail.] Actually, according to wikipedia, metaprogramming involves only rewrites
| | |   | | 170146 [james graypr] That's not how we generally use it in the Ruby community, but keep in
| | |   | + 170117 [ruby-ml magi] On 2005.12.11 10:34, "jonathan <zjll9@imail.etsu.edu>
| | |   | | 170120 [zjll9 imail.] Oooh.  That's cool!  In the case I was envisioning, I would want to eval
| | |   | | 170147 [ruby-forum-r] Just to be clear (I think you have the right idea, but for the
| | |   | + 170162 [dblack wobbl] Every object (almost) can have a singleton class, including Class
| | |   |   170198 [zjll9 imail.] Oh.  That's a neat way of doing it.  Would the code below also work in
| | |   |   170199 [ruby-ml magi] On 2005.12.12 13:07, "jonathan <zjll9@imail.etsu.edu> <zjll9@ima"
| | |   |   170409 [zjll9 imail.] Why is the code above unadvisable?
| | |   |   170415 [ruby-forum-r] I personally think the idiom is a bit suspect but it could
| | |   |   170425 [zjll9 imail.] I don't really see how duck-typing is relevant, but I would assume that
| | |   + 170206 [martindemell] It's not a subclass, it's an anonymous proxy superclass. It goes into
| | |     + 170411 [zjll9 imail.] So, this means you lose the functionality of a?  I thought the whole
| | |     | 170413 [zjll9 imail.] Oops. Nevermind the part about losing functionality.  However, I think
| | |     + 170418 [gene.tani gm] ...
| | + 169756 [sean.ohalpin] Heu magister carbunculi! ;)
| + 170201 [mark.ericson] I'm curious why "class method" is being avoided?   It certainly seems
|   170203 [hal9000 hype] I think "class method" is used in our community, but it is considered
|   170209 [perrin apoth] By the way . . . has anyone considered a name like "singular"?  What
|   + 170215 [ruby-ml magi] I advocate "pouch" :)
|   + 170446 [groups grand] Well, I'm having a terrible time following the distinction between the
|     + 170449 [michael.ulm ] Chunky Bacon Class!
|     + 170468 [dblack wobbl] First, there's an existing term (singleton method/class) that's under
|     + 170587 [zjll9 imail.] I believe, and there is a slight chance that I'm wrong, that the terms
|     + 170588 [zjll9 imail.] Well, I think 'simpleton' and 'singleton' are synonymous terms (about
|       170591 [dblack wobbl] I think you're laboring under a misunderstanding.
|       + 170599 [zjll9 imail.] I don't think so.
|       | + 170601 [dblack wobbl] This seems to be some kind of play on words.  "Simpleton" is not an
|       | | 170604 [zjll9 imail.] Yea, I agree there is some word playing going on (it may be kinda like
|       | + 170613 [rosco roscop] Lol!
|       + 170665 [logancapaldo] charset=UTF-8;
|         170724 [zjll9 imail.] What is the source of this definition?  This could be my vindication. :)
+ 169523 [transfire gm] In Ruby a class is an object too. So it can have it's own methods just

^ A small query
169525 [srinivas.j s] Dear all,
+ 169531 [dandiebolt y] Dear all,
| 169545 [srinivas.j s] I see that it does take care of nesting. But, since
+ 169533 [nobuyoshi.na] Fortunately, no.  On dynamic languages such as Ruby, it would
| 169543 [batkins57 gm] Isn't that sample the same as obj.instance_eval ?
+ 169565 [bob.news gmx] obj.instance_eval do
  + 169611 [rampant gmai] def with(obj, &block)
  | 169617 [james graypr] Ah yes.  This actually does what you asked for.  Ignore my incorrect
  | 169620 [mental rydia] In either case, caveat nuby -- within the block 'self' will refer to
  + 169614 [james graypr] class Object

^ YAML can not accept "\t" under windows!
169527 [capitain gma] when i try this code
+ 169550 [dooby d10.ka] Which proves that if you try hard enough to break something,
| 169624 [capitain gma] I meet the same problem when using rubyonrails
+ 169551 [malte__ gmx-] It doesn't under Linux either. YAML does not like tabs.
  169631 [capitain gma] 5 min ago, I realized that the ruby version in my linux server is
  169640 [shot shot.pl] that question being 'Why does YAML forbid tabs?' :o)

^ Re: Weird Numbers (#57) Solution
169546 [rubyforum.20] I was impressed when I started going through 1..1000 in under 15

^ YAML hash of array (ruby <-> perl)
169556 [zhimin.wen g] Given the data of h={"a"=>[1,2]}, perl's YAML gives the result of
169557 [dandiebolt y] I get a space after "a:"
169558 [zhimin.wen g] My version of ruby is

^ Suggestion to the Pragmatic Programmers
169567 [xrfang hotma] I recently purchased the PickAxe 2 PDF edition. I intended to use it to
+ 169576 [james graypr] orders@pragmaticprogrammer.com
+ 169615 [fugalh gmail] While I don't have pickaxe2, I do have the rails book and I find the
| 169619 [danieljohnle] Acrobat Reader (or Adobe Reader as its now called) does indeed have
+ 169693 [cyberco gmai] Totally agree. I also bought PickAxe II recently and even mailed the

^ Gem errors
169569 [bwalling gma] I'm trying to get going with Rails, but gem is giving me errors with
169585 [tom infoethe] Hm, yup, there seems to be some problems with the gem mirroring system.

^ ...rubygems... in require: no such file to load
169572 [wybo servaly] I have a script requiring rubygems, rio, and more, plus a module in a
169626 [jim weirichh] ...rubygems... in require: no such file to load
170045 [wybo servaly] Thanks, Jim. This helped: we finally found out that the session gem wasn't

^ [SUMMARY] Weird Numbers (#57)
169574 [james graypr] In reading through all the interesting solutions to this quiz, I noticed two

^ do/end vs braces
169578 [slitt earthl] It looks to me like when you use an iterator (each for instance), you can make
+ 169579 [joevandyk gm] Typically,
| + 169591 [james graypr] Another convention some use is that { ... } are for the times when
| | 169594 [joevandyk gm] Good point.  And also use { ... } if you want to do crazy chains like
| | 169595 [joevandyk gm] Oops, that first 'i' should be an 'a'.
| + 169612 [mental rydia] I can promise there's no speed difference.  They both parse to the
| + 169637 [martindemell] matchit.vim
| + 169876 [ysantoso-rub] I am not sure why Pickaxe mentioned this convention that is based
| | + 169883 [daniel.cedil] In the end doesn't it all come up to a matter of preference? I prefer
| | | 169893 [gwtmp01 mac.] I find the different precedence useful.
| | | 169894 [transfire gm] I've sometimes thought, "man wouldn't it be tight if we had some sort
| | | 170050 [chneukirchen] /\
| | + 169905 [ezra yakimah] Yohanes-
| |   169929 [ysantoso-rub] Thank you for the thought, although I can't use that as I'm using
| + 169896 [neil hakubi.] I use do .. end always.  I find it easier to read, and more in line with
+ 169593 [james graypr] Hope that helps.
+ 169603 [daniel.schie] There's a slight difference in how they're parsed.
  169752 [slitt earthl] #!/usr/bin/ruby
  169760 [lukfugl gmai] ~$ cat test.rb
  169772 [slitt earthl] Confirmed! Thanks Jacob. This is the first time I've seen Ruby conflict with
  + 169773 [paul nospam.] Interestingly, it worked for me with a space or without the parens when
  | 169780 [slitt earthl] It works as expected with braces, but not with do/end.
  + 169808 [mental rydia] =20
  + 169822 [logancapaldo] irb(main):003:0> puts ("Hello", "World")
    169824 [perrin apoth] I'd be happy with it either way, as long as it's consistent.
    + 169839 [dooby d10.ka] Without space, it's consistent.
    | 169906 [perrin apoth] There's a problem of understanding there, not of consistency.  When you
    | 169953 [lukfugl gmai] 1) Choice of block delimiters has no more influence on whether
    | 169971 [perrin apoth] [lots of stuff]
    + 169850 [slitt earthl] Yes, at least the warning would get me out of the habit ast.

^ Retrieving PID running time
169586 [phil pricom.] People,
169599 [joevandyk gm] That information should be in /proc/<pid>/stat.  Look at the man page
169605 [phil pricom.] ptime = Process.pid.time
+ 169623 [gwtmp01 mac.] This sort of thing is very platform specific.  I'm assuming
| + 169629 [Daniel.Berge] It's not in the standard library, but there is sys-proctable, available on the RAA.
| + 169643 [joevandyk gm] I thought Process::times just returned the system and user cpu time,
|   169648 [gwtmp01 mac.] I assumed the OP was looking for the system/user time not the clock
+ 169644 [joevandyk gm] class Process

^ Re: ArachnoRuby -- a professional Ruby IDE
169604 [Patrick.Benn] I never said it would be easy.  ;)

^ Best Practice Advise for a Total Ruby Beginner
169609 [crosone gmai] Hey, I've just started running through the first edition of
+ 169613 [M.B.Smillie ] Basically, yes.  It's generally referred to as 'encapsulation' in
+ 169618 [jellen rubyc] class Man

^ ruby newby
169632 [schmitt num.] I'm trying to write a parser for cooking recipes.
169634 [ef alum.mit.] This doesn't do what you want.  It's trying to call the "find_start"

^ fastcgi and shared interpreters
169636 [james_b neur] I'm doing more work with fascgi and scgi, and I'm looking for some
+ 169655 [jeremy bitsw] How you process requests in a FastCGI or SCGI handler is up to you.
+ 169787 [ara.t.howard] fastcgi is process based - you don't need to worry about any concurrent access
  169818 [james_b neur] Right.  There's no telling what other app might be trying to access the
  169823 [jeremy bitsw] Most FastCGI implementations work this way, but it is not a rule.
  + 169825 [jeremy bitsw] In fact, FastCGI can handle concurrent requests on concurrent
  + 169827 [james_b neur] I'm writing and deploying Rails and Nitro apps and using fastcgi/scgi at
    169829 [jeremy bitsw] Zed's SCGI Rails runner is threaded but serializes request processing
    169833 [george.mosch] Nitro also supports multithreaded applications. Nitro and Og are (or

^ [ANN] Rails RC5 (0.14.4): Next stop one-oh (really, this time!)
169641 [david.heinem] It's been a month since we promised that RC4 would be the final

^ ordered/sorted hash
169642 [robert_kuzel] is there anywhere a class that does soemthing
+ 169646 [transfire gm] The dictionary class in Facets/Calibre is basically the ordered hash
| + 169664 [robert_kuzel] the only real requirement is
| | 169713 [SimonKroeger] class SortedHash < Hash
| + 169670 [robert_kuzel] another idea would be to be able to define
|   169687 [transfire gm] I see. So you want a way to tell the object itself how it's to order
+ 169647 [slitt earthl] When I tried it, it seemed that Ruby automatically sorted the keys. I'm not
| 169653 [gene.tani gm] Not sure what "it" is, but Hash#sort will convert the hash to a list of
| 169654 [Daniel.Berge] hash.sort.each{ |e| puts "#{e[0]} => #{e[1]}" }
| 169667 [robert_kuzel] this has the effect that clients of that hash
| + 169675 [transfire gm] Thank robertj I'll work on it now.
| + 169685 [james graypr] You could easily wrap a Hash and provide an each() that sorted before
|   169795 [hal9000 hype] I've been discussing this off and on for years. What you say is true,
|   170149 [w_a_x_man ya] ["x", "a"]
+ 169651 [billk cts.co] Perhaps rbtree?
+ 169788 [ara.t.howard] require "alib"
  169799 [transfire gm] Insertion order?
  169802 [ara.t.howard] require "alib"
  169895 [transfire gm] Okay, I have preliminary implementation of Dictionary class with
  170056 [robert_kuzel] thats way cool.
  170137 [transfire gm] Good good. I'll do that.

^ SwitchTower for non-Rails projects
169652 [slavomir23 g] Is there anyone out there, who has used SwitchTower for non-Rails

^ Html parses
169657 [marcio.franc] Does anyone knows about an html parser in ruby?
+ 169683 [james graypr] James Edward Gray II
+ 169699 [gene.tani gm] I'm time trialling python and ruby parser right now, so I'm going to

^ New guy... Intoduction and first question on some direction.
169660 [rakxzo gmail] I'm learning Ruby.  I've been working on an automated web application
+ 169662 [bob.news gmx] That's great news!  Welcom aboard.
+ 169666 [akonsu gmail] 1. what should happen if the files have different structure (different

^ sync.rb difference between Sync::UN, Sync::EX and Sync::SH
169665 [transfire gm] In sync.rb what are Sync::UN, Sync::EX and Sync::SH all about?
+ 169671 [transfire gm] Oh, one other thing. SyncEnumerator has nothing to do with Sync right?
+ 169684 [vjoel path.b] EX is exclusive: if a thread requests an EX lock, no other threads may
+ 170242 [transfire gm] No one know? I assume Sync::EX when underlying data is gogin to change

^ invalid arg to sysread deep within protocol.rb
169673 [williamerubi] I just made a script that fetches certain web pages, using Net::HTTP,
169718 [logancapaldo] Maybe there aren't 1024 bytes left? According to the docs sysread is
169720 [williamerubi] Yes, I'm sure.  Now that I look back at my original post, I notice that
169740 [williamerubi] This seems to occur every few thousand iterations (not the same number

^ Transparent Caching Idiom
169674 [b gimpert.co] I've made good use of this idiom recently, and wanted to share it.
+ 169715 [daniel.schie] Neat. Though it would be cool if the methods that were to be cached were
| 169785 [gene.tani gm] I got this bookmarked, When i get time, i'll have to compare to prior
| 169841 [bob.news gmx] Kind regards
+ 169917 [daniel.schie] This is a touched-up version of your code.
threads.html
top