255420-365488

255168-320884 subjects 255653-256345

Default IRB Directory
255420 [rpgaction@gm] I'm new to Ruby, and I've never used a similar language that could be
+ 255476 [email2nilez@] ...
+ 255512 [vasudevram@g] Create a shortcut on the Windows Desktop for IRB using Windows
| + 255513 [vasudevram@g] to do it. From your description it looks like you're not familiar with
| + 255566 [nobu@ru y- a] ruby -C "somewhere you want" -S irb
|   257035 [vasudevram@g] Cool, didn't know that, thanks. Good thing I came back to look at this
+ 255520 [dejan.dimic@] Can you be more specific what you try to achieve?

Advising JRuby code from AspectJ?
255423 [ sue@su .n t] We're developing a RESTful web application, and we're looking at running
255498 [deanwampler@] ...

How to access response code with mechanize
255424 [tjacobs-sndr] I have a code segment which is intended to catch ResponseCodeError
255425 [aaron@te de ] begin
255490 [lparravi@gm ] begin

Unit testing idiom
255429 [alex@bl ck e] It's always bothered me having code and unit tests in different places -
255463 [rick.denatal] I don't know that I agree with your premise.  While it might seem

how to use a ActiveScaffold to list a page not the first one
255431 [gaoxt1983@16] Now I use active scaffold to generate list page, but now I must use

executing sudo from ruby
255438 [kazaam@ol co] I wanna execute in a script of mine commands like: "sudo apt-get clean"
+ 255441 [fwmailinglis] charset="US-ASCII"
+ 255443 [useless@us l] sudoeruser ALL=(ALL) NOPASSWD: /usr/bin/nano,/usr/bin/apt-get
| 255444 [kazaam@ol co] thanks for your answers but that are no options here. I know hardcoded
+ 255445 [leslieviljoe] ...
+ 255446 [alex@bl ck e] Wouldn't a setuid root script that actually calls the executable you're
  255448 [kazaam@ol co] the thing is that everything needs to be done by this script and no
  + 255451 [alex@bl ck e] After a little experimentation (on Ubuntu), it would seem that the only
  | + 255472 [kbloom@gm il] To run your editor, you'd probably need to use the -t option of ssh to
  | + 255514 [d_rems@ya oo] How about running job in a cron under root user.
  + 255464 [hutch@re ur ] If you aren't worried about security, you might try expect. Using
    255487 [kazaam@ol co] thanks for the hint but I only found this about
    255504 [hutch@re ur ] I used the unix version of the command directly. The man page is

[Ruby] Has any one created a FaceBook app in Rails
255439 [arjun4ruby@g] ...
255526 [james.herdma] ...

[ANN] Garden's Point Ruby.NET compiler 0.8 beta released
255440 [leslieviljoe] ...

Bug in String#unpack on windows or ??
255450 [d_rems@ya oo] I am trying to save attachment(s) from mail read with net/imap.
255452 [alex@bl ck e] Try File.new('att.tif','wb+').write(att).  From memory, the 'b' in 'wb+'
255453 [fred@la av .] Mode   Meaning
255457 [shortcutter@] That's what I would do for binary files.  It also helps documenting.
255570 [d_rems@ya oo] Yep. Thats it. Thank you guys.

Passing args from within method_missing
255454 [phillipsds@y] I have an hash of code blocks(procs?), @styles, and am trying to call
+ 255460 [stefano.croc] def method_missing style_type, *args
| 255465 [phillipsds@y] Certainly does. I knew it would be something simple, just couldn't
+ 255461 [wonado@do ne] Isn't "@styles [style_type].call(*args)" what you are looking for?
+ 255489 [rick.denatal] def method_missing(symbol, *args)

sorting arrays within an array by the first object in...
255456 [michael.ders] I have a parent array of child arrays.
255459 [james@gr yp ] parent_array.sort_by { |child_array|
255611 [dangerwillro] You have to wonder though... If you need the parent sorted, do you

define_method to define a method to pass a block to another method
255458 [jjfraney@ve ] I would like to define the following method, func, using define_method
255496 [novakps@gm i] Sorry I don't have time to work out a more complete answer, but check
255636 [jjfraney@ve ] Paul,
255685 [george.ogata] Correct.

Getting Ruby
255467 [Reid.Thompso] Given that Debian and UBUNTU break ruby up into a multitude of sub
+ 255474 [crowell07@li] On a related topic, it turns out that if you try to compile ruby
| + 255479 [peter@pe er ] That's not been the case for me installing on Ubuntu, where I only
| | 255493 [rick.denatal] Same experience here.  However it should be noted that although this
| + 255480 [not@ge to .o] # ruby -v
| + 255481 [znmeb@ce ma ] I suspect your system isn't configured correctly. I've re-compiled Ruby
|   255539 [crowell07@li] Other people have posted that it works fine for them with ruby 1.8.
+ 255500 [akulbe@gm il] ...
  255510 [Reid.Thompso] I guess I was a bit terse in my original email.  What I was hoping to

File.new and non-existent directories
255483 [jtkimbell@ya] I may be wrong, but after some testing it appears to me that when I
+ 255484 [lparravi@gm ] You could use Dir::mkdir or FileUtils#mkdir to create a directory
+ 255485 [jameskilton@] ...
  255486 [peter@pe er ] require 'ftools'
  255495 [jtkimbell@ya] Thanks everyone for your help!

why writing the file is partial
255488 [chen_li3@ya ] Thank you for your valuable inputs for my previous post.
255491 [shortcutter@] Reading and writing one file at the time is a dangerous thing to do -
255497 [rick.denatal] Right,  I think what's happening here is that he reads the first line,
+ 255499 [chen_li3@ya ] What am I supposed to do if the replacement is not same size?
| 255503 [rick.denatal] Write to another file, then rename when you are done.
| 255537 [shortcutter@] And you can even do it in a one liner.  See ruby's command line options
+ 262525 [chen_li3@ya ] Now I work on a small project with deals with process files and upgrade

Manual Garbage Collection
255494 [spam@wo ds .] building.  For some reason(which I haven't identified but I suspect is
+ 255501 [rick.denatal] Not very likely, the GC if anything tends not to free objects which
| 255536 [cwoods@cf ne] Ok, I'll see if I can find(and hey, maybe disable) ruby-gnome's
| 255542 [cwoods@cf ne] If anyone is interested in knowing more, I've continued this thread in
+ 255502 [jameskilton@] ...

Ruby Hash Querying
255505 [kwestin@gm i] I am new to Ruby and have run into a small snag. I have a hash like
+ 255507 [kwestin@gm i] OK I answered my own question...sorry. But here is the answer in case
+ 255509 [Daniel.Kempk] The ":whatever" is a Ruby-Symbol, and you're trying to kinda "fake" it
  255511 [kwestin@gm i] Great thank you. That is too easy. I am liking this.

How can I get the local machine's netmask programmatically?
255519 [wolframarnol] I'm working on a Rails app that needs to restrict certain privileged
255530 [jan.svitok@g] what operating system? windows/linux(distribution?)/osx?
255547 [wolframarnol] Linux.
255550 [Reid.Thompso] Create a socket and pull it from the socket structure.
255555 [Reid.Thompso] see if this works....????
255627 [list.rb@gm i] I spent quite a bit of time last night trying to figure this out to no
+ 255630 [Reid.Thompso] 1) I was previously aware of RubyInline  -- so didn't have to
+ 255632 [Reid.Thompso] ...

[ANN] Remindre of Ruby User Group Meeting for Milwaukee tonight at 5:20
255521 [tdjordan@gm ] "Nothing will ever be attempted, if all

Text/GFX rendering. Which lib ?
255522 [mathieu.chap] Dears,
255523 [doodpants@ma] On Jun 13, 4:40 pm, "Mathieu Chappuis"
255640 [mathieu.chap] You probably right, as a text-mode afficionados I've neglected such libs.

[Ann] Labrador-0.0.1 pre alpha released
255528 [robert.dober] the very diligent folks from RubyForge have approved my request early
255531 [robert.dober] this might be useful ;)

question: referencing a variable with a variable
255538 [just_a_techi] I come from a perl background.  I have gotten in the habit of using
+ 255540 [just_a_techi] s/print $$var_name/print $$this/
+ 255543 [gavin@re in ] In Ruby, a variable is a reference to an object. While you can create
+ 255590 [misaka@po ox] I don't think that symbolic references directly supported in Ruby, but
+ 257562 [erik@ho le s] There are no soft references in ruby. However, you can use symbols to
+ 257569 [robert.dober] Sorry if I am asking something stupid here but my $perl ;) days are

mechanize newbie
255541 [bladenut@gm ] Okay, Ruby in general newbie, but I did the whole shovell project for
255546 [jeff.fry@gm ] that what you are trying to do is super easy in Watir: http://openqa.org/watir
255608 [onebitcipher] ...
255642 [bladenut@gm ] Nathan,

ruby/eclipse in a mixed language project
255545 [jeff.fry@gm ] The shop I'm working for has a bunch of (non-GUI) test automation

decrypt challenge - perl encrypt with ruby decrypt
255548 [aktxyz@gm il] Ok, so I am trying integrate with someone who is sending me a string
255612 [onebitcipher] ...
255869 [martin@sn wp] des-ede3-cbc       Three key triple DES EDE in CBC mode

Twain and sane
255549 [giulianisanc] How to access a scanner using ruby through twain and sane ?

Ruby Syntax and SOAP Web Service
255551 [   me@me co ] I need a good tutorial to show how to create a RUBY
255565 [bmunat@gm il] I never did find a decent tutorial on using SOAP in Ruby. However, I
335557 [mario@be wa ] mH=Hash.new()

more mechanize
255553 [bladenut@gm ] Okay, I managed to get mechanize to login for me. Now I am pulling
255564 [aaron@te de ] puts page.body

Dynamically referencing class constants?
255554 [list.rb@gm i] ...
+ 255556 [cdcarter@gm ] Socket.const_get("SEEK_CUR")
| 255568 [list.rb@gm i] ...
+ 255557 [Reid.Thompso] puts "Socket::#{i}"
  255558 [Reid.Thompso] doh!!! sorry, missed the dereference...

rubyscript2exe on OS X
255559 [kw@co eb ke ] Anyone using rubsyscript2exe on Mac OS X to generate standard Mac
255580 [ariekusumaat] try use platypus http://sveinbjorn.org/platypus
255615 [kw@co eb ke ] Any examples of Ruby-Tk applications that are deployed in this fashion?
255661 [dangerwillro] Depends what you want to do.

ruby chinese character encoding problem with SQL
255560 [bobras747@gm] My SQL query has some chinese characters which are getting messed up.
255577 [AEtzold@gm .] Dear Bob,

form handling using ruby
255567 [budhotei@gm ] I'm a newbie to ruby and web programming. I created a very simple html
255604 [dangerwillro] Hey Mark,

How to detach mail attachments with Net::IMAP
255571 [d_rems@ya oo] Since documenattion on this topic is very "non existing" I thought I

Mail Using SMTP Problem
255572 [dgirdhar@ar ] Please help me to resolve the following issue. When i am running
255575 [dan@fl en ra] Remove the spaces from in front of the second 'END_OF_MESSAGE'. The end
255576 [dgirdhar@ar ] Thanks Dan, it is working.

How to functional test a action that render a partial
255573 [gaoxt1983@16] or just update some doms, of cause using rails functional test

Dir copy with rename
255574 [Gilbert.Rebh] i want to copy a dir recursive with all files included,
255582 [skoot@id ic ] Are you sure the code you posted here is the code you really run?
255585 [Gilbert.Rebh] now i have
255587 [shortcutter@] Your basic flaw seems to be that although the subject talks about "copy
255594 [Gilbert.Rebh] /*
255596 [skoot@id ic ] The standard procedure with 'find' utility, when performing recursive
255598 [Gilbert.Rebh] /*
+ 255601 [skoot@id ic ] 1) copy the structure
+ 255669 [charles.nutt] JRuby does have fileutils...are you sure your environment is set up
  255693 [Gilbert.Rebh] Behalf Of Charles Oliver Nutter

[ANN] raop-client 0.1.0 Released
255578 [aaron@te de ] raop-client version 0.1.0 has been released!

installed mysql gem on windows but it isn't working
255579 [grehom@nt wo] require 'dbi'
255701 [grehom@nt wo] I waded into this code using the -r debug option and it seems that the

Problem using net/ftp om SunOS 5.8 - libgcc_s.so.1 not found
255581 [funkytwig@gm] compress_n_ftp.rb: fatal: libgcc_s.so.1: open failed: No such file or

Subject: [ANN] textpow 0.9.1 Released
255583 [dichodaemon@] textpow version 0.9.1 has been released!

Re: Subject: textpow 0.9.1 Released
255584 [dan@fl en ra] Hmmmm, can you explain how multiple subtractions in scopes work?
255893 [dichodaemon@] Well, I've found them while debugging the Brilliance themes in
255934 [dan@fl en ra] Yes, I see them now. OK thanks for the tip.

REACH Technologies
255589 [dglmohankuma] <a href="http://www.reach-tech.com">REACH Technologies</a>

RAILS: problems loading fixtures
255591 [mark.swinson] I'm having a bizarre problem getting my fixtures to load when running my

[SUMMARY] Mexican Blanket (#127)
255593 [james@gr yp ] Several solutions to this quiz called out to RMagick to draw pictures of their

[ANN] Ruby2CExtension 0.2.0 -- Now with optimizations
255595 [dbatml@gm .d] I am happy to announce the release of Ruby2CExtension 0.2.0.
255603 [eric.mahurin] Thanks Dominik!

"case when" executes a symbol as method
255599 [fla@sy ap s.] I just stumbled upon some interesting behaviour of case when and wanted
+ 255602 [twifkak@co c] Syntax/whitespace thing. No special meta-magic.
+ 255607 [dblack@wo bl] when "Hello": hello
  + 255657 [fla@sy ap s.] Thanks David and Devin for pointing that out! Looks like the syntax
  + 255921 [drbrain@se m] Oh good, now I have a real reason to hate 'when blah:' (besides it
    255933 [nobu@ru y- a] Don't mind, it is deplicated in 1.9.

[ANN] soap4r-1.5.6
255600 [nakahiro@sa ] 'SOAP4R' is an implementation of SOAP 1.1 (W3C Note).

ezcrypto
255613 [ bob@bo .c m] require 'ezcrypto'
+ 255616 [jameskilton@] ...
| 255617 [onebitcipher] ...
+ 255643 [james@di su ] Hmmm I get the same problem, seems like it dies if the file is greater
  + 255646 [onebitcipher] ...
  + 255711 [james@di su ] here's some basic code that will encrypt a file with blowfish and CBC,
    + 255712 [james@di su ] Also note that it does not write the IV at the beginning of the file,
    + 255775 [onebitcipher] ...
      256024 [james@di su ] File.open("test.enc",'wb') do |enc|

appending the contents of multiple text files into 1 file
255614 [pdanese@Ri -] is there a simpler/more idiomatic way to append/join the contents of
255624 [stefano.croc] File.open('C:\mynewfile.txt','w') do |f|

gems on Debian
255618 [seti_out@tq ] after installing rubygems package in Debian, i can't seem to use the
+ 255620 [caduceass@gm] This may be a dumb question, but I've seen a lot of people missing
+ 255628 [bas@va -g ls] =20

[Rake] call a task of a namespace from an other task.
255619 [stephane.wir] I try to call a task of a namespace from an other task !
255635 [showaltb@gm ] Well, you're not strictly "calling" the task. You're making it a dependency.
255696 [stephane.wir] yes, sorry.

Re: call a task of a namespace from an other task.
255621 [stephane.wir] Ok, I found a solution but I don't know if it's a good solution.

help
255622 [mark@si es l] help
255625 [Reid.Thompso] Help is on the way -- should be there shortly.
255782 [dangerwillro] Perhaps we should set up a "helpmarkhenderson" site?

Runtime disparity - Same program in Perl and Ruby
255626 [kaldrenon@gm] the two versions, though.
+ 255639 [dummy@ex mp ] Did you write it in basic or in Perl?   :-)
| + 255644 [kaldrenon@gm] Thanks for the reply, John. There are a number of good tips in your
| | 255868 [bik.mido@ti ] Just try.
| + 255867 [bik.mido@ti ] return unless -f and /^\S+_\d{3}/;
+ 255648 [oga_emmanuel] It would help to have a view into the input file an to know what your

Building 1.8.6-p36 with Sun Studio 12 compiler
255631 [markea01@sb ] All -
255935 [nobu@ru y- a] There are also {get,set,make}_backtrace functions, they have no

Characters and strings oddness
255634 [stefan.kruge] I'm trying to learn the language, coming from a long background in Perl.
+ 255637 [  z@wz h. om] string[0].chr == 't'
| 255641 [gavin@re in ] or string[0..0] == 't'
+ 255665 [dan-ml@da 42] How is that supposed to work? With the initial anchor there's no way

UPDATED: Building 1.8.6-p36 with Sun Studio 12 compiler
255638 [markea01@sb ] All -
255853 [ryand-ruby@z] Please send reports like this to ruby-core, where they can make a

is self.var in a class the same as @@var ??
255645 [emmanuel@li ] Is this the same?
255647 [robert.dober] No it is not, as a matter of fact the second idiom is not correct

Directory tree traversal fun
255649 [grblanco@gm ] I want to write a recursive file renamer. It will work such that given
255659 [  z@wz h. om] def rename( headOfTree, what, withWhat )

Changing registry values with Win32::Registry
255651 [collintmille] I'm trying to change a registry value for an IPTV SDK
+ 255699 [jan.svitok@g] Win32::Registry::HKEY_LOCAL_MACHINE.open("SOFTWARE\\PATH_TO_KEY\\",Win32::Registry::KEY_WRITE).write("IgnoreTinyIFrames",Win32::Registry::REG_DWORD,0)
| 255710 [dejan.dimic@] Look at https://www.ruby-forum.com/topic/76585
| 255765 [collintmille] ...
| 365440 [tonavaneet@g] How do we handle null value from opened HKEY instance. if
| 365442 [jgabrielygal] I have no idea about that API, but if read_i is returning nil for
| 365443 [tonavaneet@g] Thanks for your reply.
| + 365444 [jgabrielygal] I don't know what the API returns in that instance. Can you try this
| + 365445 [phasis@gm il] begin
|   365446 [tonavaneet@g] Thanks Park...
|   365451 [hramrach@ce ] I would do something like
+ 365488 [rogerpack200] Posted via http://www.ruby-forum.com/.
threads.html
top