214499-216256

214270-232793 subjects 214708-314129

Benchmark for Ruby
214499 [robert.dober] ...
214542 [znmeb@ce ma ] Yeah, I'm with you. I actually took a look at the shootout page. First
+ 214552 [igouy@ya oo ] Grab the CVS tree
| 214553 [robert.dober] ...
+ 214564 [hgs@dm .a .u] <OT>I've tried, but FORTH still hasn't clicked with me yet...</OT>
| 214630 [znmeb@ce ma ] <not-quite-OT>
| 214641 [hgs@dm .a .u] Thanks, I'll reply off list about that.
| 214644 [kenosis@gm i] I can't recall whether I read about this on this site or in some
| 214649 [pat.eyler@gm] RedHat Magazine had an article on GCC optimizations that talked about
| 214660 [znmeb@ce ma ] Well ... the good news is that I have gcc 4.1.1 and a "test suite"
| 214682 [sylvain.joye] For those who are interested, I already measured the effect of GCC
| + 214734 [robert.dober] ...
| | 214839 [znmeb@ce ma ] 1. In his specific case, the choice of a built-in matrix multiply and inverse
| + 214842 [znmeb@ce ma ] Very interesting ... 22 percent speedup overall. I believe, though I'd need to
+ 214578 [asbradbury@t] <snip some very interesting benchmark methodology>
| 214617 [znmeb@ce ma ] Despite the fact that gizmos like hyperthreading and dual-core
| 214626 [nospam@no it] / ...
+ 214581 [halostatue@g] Playing with compiler flags is of limited utility across the board.
  214582 [garbagecat10] ...
  214592 [srinivas.j@s] I have a lot of requirement of the kind shown below, where ':asdf' would
  214631 [garbagecat10] ...

not finding a breakpoint + values are nil
214503 [randomgeek@c] Ruby seems to be passing over a breakpoint in a class initialize
+ 214507 [gwtmp01@ma .] Is this perhaps an issue of inheriting from a core class?  I know
+ 214625 [rick.denatal] Well I'm not sure what else is in your real code, but I just tried
| 214679 [randomgeek@c] Does it work in a Rails app?  Breakpoints in the controller file work,
| 214692 [ezmobius@gm ] Breakpoint is broken in ruby1.8.5. Maybe that is your issue?
| 214716 [randomgeek@c] I have 1.8.4.
+ 214722 [randomgeek@c] Okay, it looks like require doesn't look for a new copy of a file when

problem - logging for mt programs
214504 [ara.t.howard] anyone out there have good ways of dealing with multithreaded logging?  my
+ 214785 [randomgeek@c] You mean other than assigning each thread a separate file?
+ 214841 [alex@bl ck e] I handle this by having each thread *always* drop its thread id into the

Problem with generated soap requests using the WSDLDriverFactory?
214505 [dsledge@ap r] ...
215345 [nakahiro@sa ] Regards,
215432 [dsledge@ap r] Thank you :-) , I had filed a bug on rubyforge (
216104 [nakahiro@sa ] Thank you.  I fixed the problem in the changeset 1724
+ 216138 [dsledge@ap r] ...
+ 216139 [dsledge@ap r] ...

[OT] Re: not finding a breakpoint + values are nil
214506 [ara.t.howard] if you haven't used narray you should check it out - it'll give you beautiful

[ANN] codeforpeople's rubyforge 0.2.1 released
214510 [ryand@ze sp ] I've just released version 0.2.1, fixing a gem deployment issue and

script local variables - the root of all mystery?
214511 [jsn.s.rubix.] I have a script with top level variables in it (i.e - variables that
+ 214512 [jsn.s.rubix.] I don't know why this gets sent twice. All my other proxied mail
+ 214546 [shortcutter@] I cannot exactly tell what went wrong in your case but I do know that

script for ftp using hash
214514 [cristianomac] I've written a script that transfer files with ftp.

Compile failure on IRIX 6.5
214515 [joevandyk@gm] Any ideas?
214555 [nobu@ru y- a] Sorry, my mistake.
214556 [matz@ru y- a] Apply the patch, please.

Keep only one part of a string
214520 [user@do ai .] I'm pretty sure there is a String method that would keep only the first
214524 [eero.saynatk] ri String#slice, ri String#slice!
214562 [user@do ai .] Fine ! Thanks... About the same topic (Strings) I wonder how to replace
214565 [nospam@no it] What something else? Please say specifically what you want to accomplish.
214566 [user@do ai .] Sorry, what I would like to know is if there is a another String method
+ 214579 [MonkeeSage@g] You want String#slice!
+ 214584 [logancapaldo] s = "REF:90 REFERAL"

Newbie regexp question
214523 [amheiserbush] I'm trying to split a formatted text file into four separate columns.
+ 214528 [lopx@ga et .] try this one
| 214531 [lopx@ga et .] Ooops,
+ 214529 [james@gr yp ] My wife, Dana Gray, is still learning Ruby so I gave her this problem
+ 214530 [mike@st k. a] You have a number of options - if your data is tab delimited (i.e.
+ 214596 [runner@be ke] I suck at regex too, I tried this as an exercise and came up with the

Re: Can you download this for me?
214526 [ihatespam@ro] I'm an idiot...

Looking for reference for Ruby/Tk and Ruby/MySQL
214527 [lynchnco@pa ] Good evening,
+ 214537 [znmeb@ce ma ] I can't help you on MySQL -- I'm a PostgreSQL fanatic. As far as Ruby
+ 214616 [chris.hulan@] Cheers
+ 214621 [hgs@dm .a .u] Resources for Tk include <a href="http://httpd.chello.nl/k.vangelder/ruby/learntk/">Ruby/Tk
+ 214763 [nagai@ai ky ] On "Pickaxe" book, "command" option of TkScrollbar and yscrollcommand
+ 215783 [lynchnco@pa ] I'm ok now with Tcl/Tk...
  215822 [znmeb@ce ma ] Some of the gems have two versions -- a source version for those folks
  215892 [lynchnco@pa ] Ed,

Vote for Ruby support in SlickEdit
214535 [gazmcgheesub] SlickEdit is a heavy duty, commercial, crossplatform, multi-language

auto indentation problem; little help please :)
214548 [gary.church1] I'm new to ruby and irb and am hoping someone can give me a helping
214549 [eero.saynatk] It is not really possible to do because irb does not know
214597 [gary.church1] Thanks for the reply.

[ANN] Ruby-VPI 7.2.0
214554 [skurapat@uc ] Version 7.2.0 (2006-09-15)

Merging two anonymous structs
214567 [user@do ai .] For example merging this one
214571 [MonkeeSage@g] It's possible, but it's probably better to use Hashes instead. You can
+ 214572 [user@do ai .] Thank you so much !! I spent 3 hours on this...
+ 214690 [skurapat@uc ] I like your variable naming style here. I'd normally write 'members'

Re: new genetic programming system for ruby
214570 [vidar@ed ei ] When I first saw this, I was thinking that it would be fun to play with
214810 [polypus@ya o] that's interesting, i'd be curious to see where you go
215152 [vidar@ed ei ] More or less, but on thinking about it a bit more I realised that there

File Merge help request from Newbie
214575 [snoopy.pa30@] First let me say that I am an absolute Newbie to Ruby.  So please be
+ 214609 [nospam@no it] / ... snip code list
| 214699 [snoopy.pa30@] snip snip
| 214704 [nospam@no it] / ...
| + 214721 [snoopy.pa30@] snip snip
| + 214956 [leandroico@g] (The File module in you particular case)
+ 214614 [pit@ca it in] Snoopy, if your data is as well structured as you've shown (minus a few
| 214695 [snoopy.pa30@] Thank You Pit.
+ 214627 [w_a_x_man@ya] dir1 = '1-Original/'
  214697 [snoopy.pa30@] snip
  214727 [sgentle@gm i] require 'enumerator'
  214849 [snoopy.pa30@] snip
  + 214853 [snoopy.pa30@] ... snip snip
  | 214888 [MonkeeSage@g] mergedata = Array.new(data.at(0))
  | 214893 [snoopy.pa30@] ..snip snip
  | 214895 [MonkeeSage@g] The split method just returns an array of every item on either side of
  | 214896 [MonkeeSage@g] Actually, there's no reason to use a regexp for a delimiter here. A
  | 214899 [snoopy.pa30@] Jordan,
  | 214916 [MonkeeSage@g] I'm sure I speak for everyone when I say that we're glad to help out.
  + 214883 [pit@ca it in] Snoopy, you mentioned in one of our posts that the suppliers might
    214891 [snoopy.pa30@] Pit,

Contracted Ruby Help
214585 [brandon@lo d] I'm new to the Ruby world and am liking it so far.
+ 214586 [wccrawford@g] Welcome!
| + 214590 [logancapaldo] I imagine you never see replies because people would generally reply
| + 214599 [jp@je fp it ] Not to dis this posters answer, but what does "local" really mean these
|   214603 [wccrawford@g] Most companies care, whether they should or not.  All the recent Ruby
|   214638 [brandon@lo d] Hey guys.
+ 214588 [phlipcpp@ya ] That tells me you don't live where I do. San Diego has quite a few Ruby on
+ 214589 [hulachr@ho m] You should try http://jobs.rubynow.com/
+ 214595 [jmg3000@gm i] My guess would be that it's off-topic here.

Rails: Transmit <select><option> value into link_to()
214594 [phlipcpp@ya ] [Still trying to safely get on the Rails mailing list...]
214607 [wccrawford@g] Do you mean to say you meant this to go there?  It... didn't.

RMagick, OS X, and granite
214600 [ruby@an hr p] ############################################################
214677 [rmagick@gm i] I can't imagine why display works and RMagick doesn't. I'm tempted to
214749 [ruby@an hr p] } >
214768 [TimHunter@nc] Good news! Thanks for letting me know.

Regular expression for string.anotherstring
214605 [bart.braem@g] I'm trying to validate a user mail address for a fixed domain with the rule
+ 214610 [nospam@no it] "string.string@domain". Yes?
| + 214669 [rick.denatal] Actually "$" matches at the end of the string or the first line break
| + 214870 [bart.braem@g] That's right.
|   + 214889 [MonkeeSage@g] test = lambda { |x| p $1 if x =~ /(\w+\.\w+)/ }
|   | 214930 [bart.braem@g] Oh boy, you are right! Thanks for the explanation.
|   | + 214938 [nospam@no it] string =~ /^\w+\.\w+$/
|   | | 214951 [pit@ca it in] This would be unnecessarily complex. Just use Bart's regexp (with \z
|   | | 214991 [nospam@no it] Not really.
|   | | + 215023 [dblack@wo bl] That replaces "this is" with "this is".
|   | | + 215026 [MonkeeSage@g] The \z matches up to the terminus of the entire string, including any
|   | + 214989 [dblack@wo bl] "Are you sure?\nabc.def" =~ /^\w+\.\w+\z/   # :-)
|   |   215100 [bart.braem@g] I meant that I want to do input validation on the entire string. It must
|   + 214984 [aledonne.lis] Bart-
+ 214723 [hhausman@gm ] /^[^@]+/

monkey-patching const_missing and friends
214619 [drjflam@gm i] In RubyCLR, I currently have a baseline dependency on ActiveRecord

Ruby on Rails mailing list server is full top
214632 [phlipcpp@ya ] I didn't say that.
214654 [halostatue@g] The Rails mailing list is no longer there. It's a Google Group, now.
214656 [phlipcpp@ya ] Yay! Could someone tell us on that page?!

readline() with editing and history?
214634 [jw@ra en in ] I'm looking for a readline() with history and editing support (like perl's
214636 [ksruby@gm il] ...
214647 [jw@ra en in ] jw@raven> irb
+ 214659 [vjoel@pa h. ] Here's a simple example that shows line editing and history (completion
+ 214686 [rick.denatal] My guess is that your installation of Ruby didn't successfully install
| 214733 [jw@ra en in ] This is suse-10.0 with ruby-1.8.2. I have installed all ruby-related
| 214754 [shevegen@li ] "If you installed ruby from source, then readline probably didn't build
| + 214769 [gene.tani@gm] here's the bit to test if readline is compiled in, from Pragmatic's
| | 214770 [gene.tani@gm] ruby -rreadline -e 'p Something'
| | 214817 [jw@ra en in ] Actually, readline _is_ available.  It just don't support line-editing and
| | 214818 [dharple@ge e] $ ri Kernel#readline
| | 214824 [jw@ra en in ] Ah, now I get it!  Thanks Daniel!
| | 214862 [logancapaldo] The return value of require is borderline meaningless. If require
| | 214866 [jw@ra en in ] Are you sure with this?  I get false even on the _first_ require.
| | 214869 [logancapaldo] Are you sure it's the first require? ;) For instance, I load readline in
| | 214876 [jw@ra en in ] Hmm, I don't have an irbrc.  I've just checked: only irb returns false, so
| + 214784 [rick.denatal] Or maybe not, since it is an optional feature, I don't know that you
+ 214687 [kbloom@gm il] you need to include the Readline module that is contained within the

Re: A better syntax highlighting color scheme for Ruby code
214642 [eero.saynatk] The wife was very enthused about the new http://www.ruby-lang.org

Rails: generate scaffold Product Admin overwrites admin pages
214643 [phlipcpp@ya ] [This post belongs on the Rails mailing list but its server is full]

not sure what is wrong. strange error
214645 [junkone1@gm ] My class declation is like this
+ 214646 [vincent.four] There is no such thing as overloading in Ruby. Your second definition
| 214653 [nsmith5@um c] It's too bad Ruby does not allow overloaded methods. It makes more sense,
| 214657 [gavin.kistne] 'Constructors' in ruby are just initializers that get run after the
+ 214648 [hgs@dm .a .u] No, you redefined it.  No overloading in Ruby (because "Duck Typing")
+ 214688 [gregory.t.br] It looks like you want to use an optional parameter

irb freaks out over a case stmt...
214652 [bitdoger2@ya] i'm writing a method within the Akill class that cascades down 2 sql
214667 [ryand-ruby@z] I can't even tell what you are trying to do / write. It looks like
214684 [kbloom@gm il] How do you turn off tab completion in IRB?
214689 [bitdoger2@ya] ...how do turn off the tab because that was the case (sort of speak)
214717 [caldridge@gm] in scite, just hit F5 to execute the app/script.. no need to past to
214910 [kbloom@gm il] I prefer my gvim and my xterm, thank you very much. How do I turn off tab
214914 [nepentherepr] irb -f --readline      #ignore .irbrc file and load readline w/o tab
214972 [kbloom@gm il] It seems that I don't have a .irbrc, but I still have tab completion. I'd
215024 [kbloom@gm il] I figured it out. Somehow, at the end of

wxRuby2-preview: strange event of TextCtrl
214655 [kuangdong@gm] evt_text(TEXTCTRL_ID){
+ 214663 [nospam@no it] You have to choose which text events you want to act on. You are presently
| 214675 [kuangdong@gm] Acutally,I wanted to do something like google suggest
| 214700 [nospam@no it] / ...
+ 214739 [alex@de et m] I don't see this behaviour. If I type in 'Hello', then select 'ello' and overtype with 'i', get_value in the event handler returns 'Hi'.

rubyinline and rails - do they play nice
214661 [inxs.hemant@] ...
214662 [francois.bea] 2006/9/15, Hemant . <inxs.hemant@gmail.com>:> Now good thing about the above controller code is that, it works. And the> bad news is, it works only once...upon the next refresh it says:>> require on /home/gnufied/.ruby_inline/Inline_FoobarController_cb89.so failed
214664 [gethemant@gm] Oh..yes,  i forgot that. After running the stuff in production mode,
214668 [gethemant@gm] I am already using Backgroundrb for several other stuff. But i am
215007 [drbrain@se m] Note that C code typically won't allow a thread switch, so the ruby
215103 [gethemant@gm] </snip>
215153 [drbrain@se m] So long as you stay inside the C function, yes.  If you call back out

Is there any way to save current job to a file in irb?
214681 [kuangdong@gm] Or is there any tool to take place of it?
+ 214693 [nospam@no it] 1. Please put your message in your message, rather than in the subject line.
+ 214701 [vjoel@pa h. ] def dump_history(file=nil)
+ 214707 [_mwryder@wo ] I use SCITE to test program fragments and can then save the code.
  214772 [gene.tani@gm] There's this, also

some default ruby extensions don't get -L/path/to/lib/dir
214683 [tim.mooney@n] All-
214725 [nobu@ru y- a] $ configure --with-opt-lib=/local/openssl/lib:/local/gnu/lib/64:/local/BerkeleyDB/lib/64
216256 [hramrach@ce ] I use a patch for pulling libs from /sw.

Re: Rails: generate scaffold Product Admin overwrites admin
214685 [eero.saynatk] That is not really an excuse :)

No regex backreference with four backslashes
214691 [gabriel.birk] require 'test/unit'
214696 [nospam@no it] To find out how your strings are being parsed, print them out. Then print
214698 [gabriel.birk] I've done that already, the test was only to show the problem: I could
+ 214702 [MonkeeSage@g] In the replacement string, a backreference is a backslash followed by a
+ 214703 [nospam@no it] / ...
  214735 [gabriel.birk] I was trying to escape some characters in a string with a backslash.
  214738 [gabriel.birk] After thinking a while about it I realized this is not correct.
  214771 [nospam@no it] / ...

Ruby keywords vs methods
214706 [chrisjroos@g] I attended Jim Weirich's talk at Rails Conf on Friday.  It was about
214714 [transfire@gm] Well, the Extensions project does this. And another way to avoid it is
+ 214720 [jtregunna@bl] That's correct. In Io, everything is a dynamic message send. There
| 214737 [chrisjroos@g] I wonder if you might point me to some references as to why you chose
| 214781 [jtregunna@bl] Io suffers from a chronic lack of documentation (one several of us
+ 214736 [chrisjroos@g] I just had a look at the extensions project (albeit briefly) and can
  214742 [pit@ca it in] Chris, just call Ruby with the -w command line option. With your example
  214746 [chrisjroos@g] Ok, so this is being pedantic, but that doesn't appear to work if you
  214747 [pit@ca it in] Works for me with Ruby 1.8.4 (2005-12-24) [i386-mswin32] on Windows 2000.
  + 214748 [verno@ma li ] Maybe also check out  metaprogramming hacks similar to the "Alternative
  + 214753 [chrisjroos@g] You are, of course, absolutely right.  I was obviously doing something
threads.html
top