[#349422] Date.parse('17:26:33 Oct 31, 2009') returns invalid date — Jacob Gorban <jacob.gorban@...>
Hi,
On 2009-11-01, Jacob Gorban <jacob.gorban@gmail.com> wrote:
Seebs wrote:
Jacob Gorban wrote:
[#349457] Running ruby on 64-bit Windows causing performance Problems — Pra Bhandar <pbhandari2050@...>
Hi,
[#349458] Homework Help - Methods — Rick Barrett <chngth3wrld@...>
The goal of this assignment is to ask the user for the price of each of
[#349475] ruby1.9.1 : Override string method — "Ts@... Thomas" <ts@...>
Thomas Sevestre wrote:
[#349478] Ruby 1.8.7 segmentation faults — Leslie Viljoen <leslieviljoen@...>
Hi everyone!
[#349503] StringIO and reopen — Hal Fulton <rubyhacker@...>
I've noticed (via my friend Taylor Carpenter) that IO#reopen
StringIO is not actually an IO object; it just mimics one. Unless
By "Should it?" I mean "in the future" -- I'm not implying there's
2009/11/3 Hal Fulton <rubyhacker@gmail.com>:
[#349519] All Gems Down? — Joshua Ballanco <jballanc@...>
I think I must be the only one using allgems.ruby-forum.com. It seems
On Tue, Nov 3, 2009 at 1:04 AM, Joshua Ballanco <jballanc@gmail.com> wrote:
Joshua Ballanco wrote:
On Nov 3, 2009, at 4:22 PM, Roger Pack wrote:
[#349527] Ruby Inline over two times slower under 1.9 than under 1.8? — "Shot (Piotr Szotkowski)" <shot@...>
I=E2=80=99m starting to dip my toes in non-Ruby coding (for performance rea=
Ryan Davis:
> — Shot, who’s off to play with RubyToC now. :)
Roger Pack:
Shot (Piotr Szotkowski) wrote:
First, thanks a lot to you and Ryan Davis for all your great help!
[#349555] Can not put @ when debuging with Windows XP Home Edition — Albert Catala <albert.catala@...>
On Nov 3, 3:39=A0pm, Albert Catala <albert.cat...@ya.com> wrote:
Luis Lavena wrote:
> Hi, I saw this link of peter krantz, but doesn't work. And in windows, I
[#349577] ruby-191-p243 or ruby-192-preview Compile error with openssl — Philippe Philos <plucas@...>
Hi,
[#349596] November Phoenix Ruby User Group Meeting — James Britt <james.britt@...>
November Phoenix Ruby User Group Meeting
[#349602] invalid date error when installing syntax gem — Joel VanderWerf <vjoel@...>
[#349616] Merging mp3 files in Ruby — Qu3ry Qu3ry <thinkinstein@...>
Suppose I have the following files to group and merge, according to
[#349620] How would you accomplish this? — George George <george.githinji@...>
Given an array of arrays for example
[#349639] super w/ implicit arguments in Ruby 1.9 — Intransition <transfire@...>
Hi--
[#349640] Odd : a = Hash.new(Hash.new) — Aldric Giacomoni <aldric@...>
irb(main):086:0> a = Hash.new(Hash.new)
Aldric Giacomoni wrote:
On Wed, Nov 4, 2009 at 9:22 PM, Aldric Giacomoni <aldric@trevoke.net> wrote:
Also, see this if you want autovivification all the way down:
2009/11/4 Martin DeMello <martindemello@gmail.com>:
Robert Klemme wrote:
[#349648] Hash#count — Intransition <transfire@...>
I want to suggest Hash#count be defined such that it counts hash
[#349685] Create HTML files using RUBY — Krithika San <skrithikaa@...>
Hi,
Krithika San wrote:
Hi Marnen,
Krithika San wrote:
I am sorry I was not clear in my previous reply. I am told not to use
Krithika San wrote:
Krithika San wrote:
Krithika San wrote:
[#349720] Executing one of several ruby objects — "dhf0820@..." <dhf0820@...>
I am trying to write a program that will load a series of DSLs (ruby
[#349734] question about variables in ruby — Mahadev Ittina <mittina@...>
hello folks i am preparing a ruby plugin for sketchup, i hope you can
[#349741] Freeze not freezing — Ralph Shnelvar <ralphs@...32.com>
Note that I am new to this list and to Ruby.
[#349745] How do I send referer in get request? — Ace Mutha <acemutha@...>
I know how to do it in post but I don't know using GET.
[#349759] reading from an external process with IO.popen — Robert Citek <robert.citek@...>
Hello all,
2009/11/5 Robert Citek <robert.citek@gmail.com>:
On Fri, Nov 6, 2009 at 5:15 AM, Robert Klemme
[#349779] accessing the element of a span — Mike Hin <michael.hincke@...>
I'm trying to test against the class name of a span. I'm iterating
[#349781] Possible to use svn as file system in rails application ? — Muruga Raj <murugarajb@...>
Hello All,
Muruga Raj wrote:
[#349782] encapsulation issue — James French <James.French@...>
Hi,
Hi --
[#349783] Ruby-Tk LIbraries Runtime Library 3.0 and Gestalt Items — Arndt Roger Schneider <arndt.roger@...>
Hi Ruby commuters
[#349788] how to read this — msoulier <msoulier@...>
I was recently looking to compute a sha1 hash in ruby, and l luckily
[#349799] LISP macros vs Ruby procs ? — Aldric Giacomoni <aldric@...>
I'm reading the LISP book on www.gigamonkeys.com to take a look at what
> LISP's ` (the backtick) is roughly equivalent to Ruby's eval with a
[#349849] RCR enumerable extra into core — Roger Pack <rogerpack2005@...>
I'm considering suggesting that the base functionality for the
Hi --
Roger Pack wrote:
>> list.map(:name)
Roger Pack wrote:
On Tue, Nov 10, 2009 at 10:47 AM, Brian Candler <b.candler@pobox.com> wrote:
[#349856] bones 3.0.0 — Tim Pease <tim.pease@...>
bones version 3.0.0
[#349862] A method that doesn't change its arguments — Timo Jeranko <jeranko@...>
At the moment I'm doing something like this:
> I would like array1 to remain unchanged. It seems a little inefficient
[#349868] Trip down memory lane... — "David A. Black" <dblack@...>
Hi --
On Sun, 8 Nov 2009, David A. Black wrote:
[#349888] Using Nokogiri — jzakiya <jzakiya@...>
I'm trying to scrape some data off websites using nokogiri
[#349913] called_from 0.1.0 released — makoto kuwata <kwatch@...>
I releaded called_from 0.1.0.
[#349926] FileString - request for comments — apeiros@...
Hi there
On Nov 8, 2009, at 7:47 PM, apeiros@gmx.net wrote:
James Edward Gray II wrote:
Hi Joel
On 9 Nov 2009, at 13:54, apeiros@gmx.net wrote:
2009/11/9 Eleanor McHugh <eleanor@games-with-brains.com>:
[#349947] camelize — Sijo k g <cijokgeorge@...>
Hi
On Nov 9, 1:43=A0am, Sijo k g <cijokgeo...@yahoo.co.in> wrote:
[#349954] Help with this — John Muller <nish.patel@...>
I have a question to answer but can not find any solution for this
[#349987] Berkeley DB BDB Install on Windows — david <davidhooey@...>
I've been scripting in Ruby (and Rails) for about two years now, but
[#350007] Good or best way to allocate a large array — Ralph Shnelvar <ralphs@...32.com>
Newbie here:
On 11/09/2009 06:25 PM, Ralph Shnelvar wrote:
Robert,
Ralph Shnelvar wrote:
Marnen,
Ralph Shnelvar wrote:
Marnen,
Ralph Shnelvar wrote:
Florian,
On Mon, Nov 9, 2009 at 5:46 PM, Ralph Shnelvar <ralphs@dos32.com> wrote:
Rick,
Hi,
Florian,
Ralph,
Florian,
What's about using C or C++ to allocate and deallocate the array? I do not
On 11/9/09, Ralph Shnelvar <ralphs@dos32.com> wrote:
[#350025] FXRuby table and color questions — Leslie Viljoen <leslieviljoen@...>
Hi people!
[#350030] Understanding Threads... — Matt White <mattw922@...>
I am writing an app that retrieves multiple web pages in one method
[#350064] File size vs. Directory size problem — "T.w.oliver@... Tom" <t.w.oliver@...>
Hi all,
[#350067] Programmers motivation: academic research — Mark Pith <mark.pith@...>
Dear Ruby community,
On Nov 10, 2009, at 1:58 AM, Mark Pith wrote:
[#350106] Installing Rails: MySQL issue? — Brian Tickler <btickler@...>
Hello,
P.S. This configuration installs Ruby, Rails, MySQL, Mongrel, Git, and
[#350142] Calling a subprocess with specific arguments and capturing its output? — Dan Q <quinxex@...>
Hi. I haven't written Ruby in a while, and I was wondering if someone
On Tue, Nov 10, 2009 at 4:00 PM, Dan Q <quinxex@gmail.com> wrote:
[#350147] Roman Numerals (Arrgh!) — Rick Barrett <chngth3wrld@...>
I have a homework assignment where I have to convert an inputted integer
On Nov 10, 2009, at 6:56 PM, Rick Barrett wrote:
On Nov 10, 2009, at 5:37 PM, Rob Biedenharn wrote:
On Nov 10, 2009, at 8:49 PM, Gennady Bystritsky wrote:
On Wed, Nov 11, 2009 at 3:51 PM, Gennady Bystritsky
On Wed, Nov 11, 2009 at 4:17 PM, Gennady Bystritsky
[#350153] Is it a bug?exec "cd" — Haoqi Haoqi <axgle@126.com>
$ cat into.rb
[#350167] Need help to detect error — V兤tor Adri疣 de la Cruz Serrano <adrian@...>
I don't know what am I doing wrong, can anyone help me?
Or anyone knows where can I contact some YAML guys to help me with this
That's bizarre. All that I can see that's different is because the failing
[#350198] Active_Ldap Base Config Question — jackster the jackle <johnsheahan@...>
I haven't done much with polling AD in the past but I am now trying to
Haven't used that particular gem (I use ActiveDirectory myself) but it looks
Putting in the full object path renders the same error message, I'm
Ah, my bad. For every complex problem there is a solution that is clear,
Sorry I just assumed: are you running rails? That's what I was using it with
[#350199] Separate code space/sandbox? — Patrik Sundberg <patrik.sundberg@...>
Hi,
On 11/11/09, Patrik Sundberg <patrik.sundberg@gmail.com> wrote:
[#350203] Rubular Rocks — Intransition <transfire@...>
Big thumbs-up to Rubular:
On Wed, Nov 11, 2009 at 7:26 PM, Daniel Berger <djberg96@gmail.com> wrote:
[#350227] exception for program running on ruby code — Ahmad Azizan <ahmad.azizan@...>
Hello,
[#350233] forking behaves differently when using apache — Nick Brown <nick@...>
I want a CGI script to fire off another process and continue executing
2009/11/12 Nick Brown <nick@nick-brown.com>:
[#350250] how to find ruby header file without platform dependency. — Jun Young Kim <jykim@...>
Hello everyone.
[#350261] Open File Remotely — Homer Najafi <homi_us@...>
I know that this question looks like a Webistrano question but since I
[#350262] Enumerable#find_yield, useful shortcut? better name? — Intransition <transfire@...>
This method has long been suggested to me as #map_detect. At first I
On Thu, Nov 12, 2009 at 9:37 PM, Intransition <transfire@gmail.com> wrote:
[#350287] queuing work in a web app (sinatra/webrick) — Gurpal 2000 <g@...>
Hi
Gurpal 2000 wrote:
On Thu, Nov 12, 2009 at 10:45 PM, Gurpal 2000 <g@gurpal.co.uk> wrote:
[#350290] DRYing a Regex — RichardOnRails <RichardDummyMailbox58407@...>
I've got a routine that works fine at building an array of upper-case
On Nov 12, 6:50=A0pm, James Edward Gray II <ja...@graysoftinc.com>
RichardOnRails wrote:
On Nov 13, 2009, at 10:11 PM, Marnen Laibow-Koser wrote:
James Edward Gray II wrote:
Hi --
David A. Black wrote:
On Nov 14, 2009, at 1:40 PM, Marnen Laibow-Koser wrote:
James Edward Gray II wrote:
On Nov 14, 2009, at 3:22 PM, Marnen Laibow-Koser wrote:
James Edward Gray II wrote:
[#350297] newbie ..need help with metaprogramming.. — Dhaval <dhavalvthaker@...>
hi, i wrote a small code to check metaprogramming in ruby..what am i
On Thu, Nov 12, 2009 at 6:05 PM, Dhaval <dhavalvthaker@gmail.com> wrote:
[#350305] erb and js question — Derek Smith <derekbellnersmith@...>
Hi All,
Derek Smith wrote:
[#350307] Ruby & Physical Computing — Omran Nazir <imran.nazir@...>
Hello,=0A=0AI'll keep this short(ish) and sweet.=0A=0ACan anyone give any a=
[#350316] scrape html gives partial result — Thufir <hawat.thufir@...>
Why does scrape.rb just result in a few lines of html, rather than an
[#350317] Create Api to create document and add,edit,delete text and t — Krithika San <skrithikaa@...>
Sub: Create Api to create document and add, edit, delete text and
Krithika San wrote:
[#350321] how to copy array in ruby — PIKI <avid.piks@...>
HI
[#350328] just for fun: oneline code for 4 language permutation — Haoqi Haoqi <axgle@126.com>
hello,happy weekday!
On Fri, Nov 13, 2009 at 3:31 PM, Haoqi Haoqi <axgle@126.com> wrote:
[#350341] Module with a class? — Matt Brooks <mattbrooks@...>
I have a file that has a class called "Core" that defines tons of
On Fri, Nov 13, 2009 at 10:48 AM, Matt Brooks <mattbrooks@gatech.edu> wrote:
On Fri, Nov 13, 2009 at 9:30 PM, Judson Lester <nyarly@gmail.com> wrote:
[#350345] Another rubygem install problem — Erik Nelson <erik.l.nelson@...>
I'm trying to install a fresh copy of Ruby into empty directory
[#350359] Trajectories — Thijs Leeflang <t_leeflang@...>
hello,
Thijs Leeflang wrote:
On 14 Nov 2009, at 23:40, Marnen Laibow-Koser wrote:
Eleanor McHugh wrote:
On 15 Nov 2009, at 00:42, Marnen Laibow-Koser wrote:
Eleanor McHugh wrote:
On Sat, Nov 14, 2009 at 8:19 PM, Marnen Laibow-Koser <marnen@marnen.org> wr=
Rick Denatale wrote:
On 15 Nov 2009, at 23:02, Marnen Laibow-Koser wrote:
On Sun, Nov 15, 2009 at 5:32 PM, Eleanor McHugh
On 16 Nov 2009, at 01:12, Todd Benson wrote:
Eleanor McHugh wrote:
On Mon, Nov 16, 2009 at 2:57 AM, Marnen Laibow-Koser <marnen@marnen.org> wr=
Paul Smith wrote:
On Mon, Nov 16, 2009 at 3:18 PM, Marnen Laibow-Koser <marnen@marnen.org> wrote:
Paul Smith wrote:
On 11/16/09, Marnen Laibow-Koser <marnen@marnen.org> wrote:
Caleb Clausen wrote:
On 11/16/09, Marnen Laibow-Koser <marnen@marnen.org> wrote:
Caleb Clausen wrote:
On 11/17/09, Marnen Laibow-Koser <marnen@marnen.org> wrote:
Caleb Clausen wrote:
On 17 Nov 2009, at 18:22, Marnen Laibow-Koser wrote:
Eleanor McHugh wrote:
On Nov 17, 2009, at 1:27 PM, Aldric Giacomoni wrote:
James Edward Gray II wrote:
On Sun, Nov 15, 2009 at 2:13 PM, Rick DeNatale <rick.denatale@gmail.com> wrote:
On 17 Nov 2009, at 19:55, Gregory Brown wrote:
On 15 Nov 2009, at 01:19, Marnen Laibow-Koser wrote:
Eleanor McHugh wrote:
On Nov 14, 2009, at 7:41 PM, Marnen Laibow-Koser wrote:
James Edward Gray II wrote:
[#350393] download Ruby for Win-x64 — Ricardo Viegas <rviegas@...>
Hi there=21
[#350394] Customized GUI — Brandon Mr <scorpionl13@...>
first off, sorry if this in the wrong place, i just signed up here.
Brandon Mr wrote:
Marnen Laibow-Koser wrote:
[#350411] NArray, How to install — Ralph Shnelvar <ralphs@...32.com>
I'm trying to install NArray so that irb can get access to its
[#350414] How to do a getPixel on Win32 using Ruby? — Jian Lin <blueskybreeze@...>
Does someone know how to do a getPixel on Win32 using Ruby? (either to
[#350454] How do I get a random number between two random numbers? — Alex Untitled <somebodydc691n@...>
I want to create a program that asks you to guess a number between two
Alex Untitled wrote:
Marnen Laibow-Koser wrote:
OK, that didn't work. That just added the two numbers. How do I make a
On Sat, Nov 14, 2009 at 8:54 PM, Alex Untitled <somebodydc691n@gmail.com>wrote:
Josh Cheek wrote:
[#350474] very newbie question — duxieweb <duxieweb@...>
Hello,
On Sunday 15 November 2009, duxieweb wrote:
[#350476] Traversing the contents of a proc (for a DSL) — Siemen Baader <siemenbaader@...>
Hi List,
Generally - no. A proc is compiled code, it doesn't remember its own source
On Sun, Nov 15, 2009 at 6:32 PM, Kyle <kcy5b@yahoo.com> wrote:
On Mon, Nov 16, 2009 at 1:50 AM, Ryan Davis <ryand-ruby@zenspider.com>wrote:
[#350484] what's || — duxieweb <duxieweb@...>
sorry just was learning ruby so have some low level questions, :)
[#350485] Using activerecord with mysql — Rob Mauchel <rmauchel@...>
Hi All,
[#350514] replace a very long string with gsub get regexp error — Ahmad Azizan <ahmad.azizan@...>
Hello,
[#350526] Newbie question: Defining a numeric type — Seebs <usenet-nospam@...>
I have a type which has a bit of internal magic, but fundamentally, I want
On 2009-11-17, Brian Candler <b.candler@pobox.com> wrote:
[#350531] Advice on setup on Mac — Sophie <itsme213@...>
[Apologies if this appears as 2 posts -- my last post never seemed to
> - Which version of Ruby to use? NetBeans shows a jRuby install +
[#350535] Any official name for Ruby's class which makes "class methods"? — Hunt Jon <jona.hunt777@...>
We all know Ruby really doesn't have class methods.
Hunt Jon wrote:
David A. Black wrote:
David A. Black wrote:
On Tue, Nov 17, 2009 at 6:30 AM, David A. Black <dblack@rubypal.com> wrote:
[#350558] Looking for Set implementation in C — "Shot (Piotr Szotkowski)" <shot@...>
Hello, good folks of ruby-talk.
2009/11/16 Shot (Piotr Szotkowski) <shot@hot.pl>:
[#350563] activerecord going slow (not in rails...) (VERY slow) — Nick Green <cruzmail.ngreen@...>
Active record is taking 7+ seconds to save one item! I'm using
[#350575] How to run a specific TestUnit if the file contain two Test::Unit::TestCase classes? — Iñaki Baz Castillo <ibc@...>
Hi, I've a file with two classes:
[#350578] Sorting array of names — Jane Doe <dianne.red@...>
Hi all,
[#350590] Google Wave: A new type of "Ruby Quiz" ? — Aldric Giacomoni <aldric@...>
Google Wave is, according to Google, "the new email". It combines email,
okay seems good. can you elaborate on this a little more? Do you want
Arun Kumar wrote:
Add me to the wave then ;)
2009/12/11 Benoit Daloze <eregontp@gmail.com>:
Fleck Jean-Julien wrote:
me too! jw@mustmodify.com ( I know, not a google wave address... try
I'll hop on the bandwagon too: add me please! (zettabyte@gmail.com)
[#350594] something went wrong — Dev Tri <divyanshutri@...>
Is this for a Rails App?
Kevin Solorio wrote:
Make sure all your gems are up to date, including the rails gem. If you are
[#350615] How to dynamically include a module and update top level? — Alexandre Mutel <alexandre_mutel@...>
Hi,
On 16.11.2009 22:01, Alexandre Mutel wrote:
Robert Klemme wrote:
On 17.11.2009 00:30, Alexandre Mutel wrote:
Robert Klemme wrote:
[#350631] Rename files... permission — Adam Folkesson <adam_folkesson@...>
Hello!
[#350654] Meaning of '!(...' EG: "myObject.parse!(argv)" ..? — Michelle Pace <michelle@...>
Hi there,
Ryan Davis wrote:
[#350666] gui designer — Ashley Bar <gossipledonkey@...>
I'm looking for something like glade that I can use in windows. I like
[#350669] What is the difference between the two following pieces of c — Doney Kaka <doneysr@...>
Don't really know where to go with this one, but I gotta know...
Doney Kaka wrote:
> Ruby is not Rails, and Rails questions are best asked on a Rails mailing
Chris Mowforth wrote:
Marnen Laibow-Koser wrote:
Chris Mowforth wrote:
> When you make incorrect statements (like "this will only be used in
[#350679] Class inside a Method Body — Mike Stephens <rubfor@...>
I have a class that works fine if I declare it outside of anything. If
The class wouldn't be defined until the method is executed, and would be
Brian
2009/11/17 Mike Stephens <rubfor@recitel.net>:
Mike Stephens wrote:
[#350705] Special characters in csv header using fastercsv — John Mcleod <john.mcleod@...>
Hello all,
On Nov 17, 2009, at 10:24 AM, John Mcleod wrote:
James,
On Nov 17, 2009, at 10:38 AM, John Mcleod wrote:
I'm not sure if the placement is correct but I'm still getting "Error
On Nov 17, 2009, at 12:26 PM, John Mcleod wrote:
You are correct.
On Nov 17, 2009, at 12:58 PM, John Mcleod wrote:
[#350748] Directory path — Adam Folkesson <adam_folkesson@...>
Hello, I hope someone can help me because I can't figure out what's
On Tue, Nov 17, 2009 at 10:00 PM, Adam Folkesson
[#350751] using FasterCSV to clean CSV file — John Mcleod <john.mcleod@...>
Hello all,
On Nov 17, 2009, at 3:12 PM, John Mcleod wrote:
Thanks for the reply James.
[#350761] Nokogiri help — Jeremy Woertink <jeremywoertink@...>
I keep getting this error
[#350764] EventMachine: dynamic "client" connections — Paul Danos <pdrizzle@...>
Thanks for reading this and thanks in advance if you provide any help!
[#350766] help with parsing — Mayur Shivakumar <sk.mayur@...>
Hi ,
[#350777] How to using golang for write a xxx.so for ruby? — Haoqi Haoqi <axgle@126.com>
you may see http://golang.org
[#350810] Exact (LISP-ish) calculations in Ruby? — Aldric Giacomoni <aldric@...>
Has anyone written a gem for exact calculations? The kind one would find
On Wednesday 18 November 2009 08:35:36 am Aldric Giacomoni wrote:
On Nov 19, 6:04=A0am, Aldric Giacomoni <ald...@trevoke.net> wrote:
On Nov 20, 5:11=A0pm, David Masover <ni...@slaphack.com> wrote:
[#350813] How to overide "include" method? — Alexandre Mutel <alexandre_mutel@...>
I tried several way, but didn't found any to override the behavior of
[#350829] Ruby/tk Help Please — Sean Ob <sob4ever33@...>
I am a complete beginner when it comes to programming and i need some
Sean Ob wrote:
No, not homework, i've graduated, i'm just trying to learn more about
Marnen Laibow-Koser wrote:
Sean Ob wrote:
i have read a lot of things pertaining to blocks, but i still don't
[#350847] Update on shoes? — Jeremy Woertink <jeremywoertink@...>
I used to use shoes all the time. I just recently started again and
[#350866] do_sqlite 10 windows 1.9 gem — jonty <jontyjont@...>
I understand that this is not yet compiled for ruby 1.9 on windows
[#350890] getting a timestamp — jp <jonhy.pear@...>
Hi,
[#350898] open a binary file-read bit-change bit-update same file — Sniper Abandon <sathish.salem.1984@...>
my Aim is i want to encrypt a file
[#350912] extending ruby with c++ on windows — Al Lo <lomov.as@...>
hello everyone
[#350918] dynamic array? — Freak Guard <freakguard@...>
I'd like to store 2d-data into an dynamic Array. The Matrix class got
Freak Guard wrote:
[#350921] Problem with gem installing — Roman Bodnarchuk <leron@...>
I am using Aptana RadRail framework. Some times, after installing and
[#350924] How to strip ruby comments in a ruby line of code? — Alexandre Mutel <alexandre_mutel@...>
Short description : My question is : do you know any available method,
Alexandre Mutel wrote:
Aldric Giacomoni wrote:
Alexandre Mutel wrote:
Brian Candler wrote:
Alexandre Mutel wrote:
Alexandre Mutel wrote:
Brian Candler wrote:
Alexandre Mutel wrote:
Brian Candler wrote:
[#350948] Using /usr/sbin/sendmail in Ruby Script — Dan Sinclair <dan@...>
Hi Guys,
[#350969] Re-opening an existing module and changing a method — Aldric Giacomoni <aldric@...>
"I hear and I forget; I see and I remember; I do and I understand."
On Thu, Nov 19, 2009 at 6:27 PM, Aldric Giacomoni <aldric@trevoke.net> wrot=
2009/11/19 Jes=FAs Gabriel y Gal=E1n <jgabrielygalan@gmail.com>:
You're doing instance methods when you really want class methods.
Julian Leviston wrote:
[#350972] Ternary Operator and Arrays — Felix Dominguez <fdacat@...>
Given:
[#350975] make an exmpersion simpler — Michal Burak <wojtekb82_23@...>
Any way to make this shorter?
Michal Burak wrote:
[#350986] Controlling other applications functionality — Mehdi Karamnejad <sepehr.online@...>
How can I access an applications objects and call their functions
[#350988] For Loop — Gilberto Gilberto <daemonracing@...>
Hello All,
On Thu, Nov 19, 2009 at 2:52 PM, Mike Stok <mike@stok.ca> wrote:
[#351010] RubyForge gem index is no more — Tom Copeland <tom@...>
Hello -
On Thu, Nov 19, 2009 at 9:36 PM, Tom Copeland <tom@infoether.com> wrote:
[#351015] Error: symbol string may not contain `\0' — Dylan Lukes <revenantphoenix@...>
Basically it's pretty self explanatory. I'm packing the following:
[#351018] eval behaves differently inside a method definition... — timr <timrandg@...>
#lets give strings the ability to evaluate theirselves as if in irb.
[#351021] UDP Proxy — Randy General <randygeneral@...>
Hi,
Randy General wrote:
Hi Brian,
[#351054] select only taking alternating values? — Dylan Lukes <revenantphoenix@...>
The problem in question seems to be that only every OTHER line of
[#351059] RubyGems current load paths — Intransition <transfire@...>
Hi--
On Nov 20, 2009, at 08:40, Intransition wrote:
[#351064] Something like puts — Ralph Shnelvar <ralphs@...32.com>
Newbie question:
[#351080] ruby gem update issue in macos 10.5.7 — Junmin Liu <junmin@...>
i was trying to update the rubygem preinstalled in macos 10.5.7 by:sudo
[#351084] Distinct Sets (#225) — Daniel Moore <yahivin@...>
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
On Fri, Nov 20, 2009 at 9:23 PM, Daniel Moore <yahivin@gmail.com> wrote:
> http://gist.github.com/240457
On Nov 22, 2009, at 1:51 AM, lith wrote:
On Mon, Nov 23, 2009 at 11:10 AM, Rob Biedenharn
Hey Rubyists!
Here's my not-fast solution:
I must admit is a very elegant solution.
[#351087] confuse about initialize hash — Zhenning Guan <g.zhen.ning@...>
def in(options ={} )
Zhenning Guan wrote:
Hi --
David A. Black wrote:
[#351099] Detective - a new ruby gem — Ahmed Eldawy <ahmed.eldawy@...>
Detective is a new gem build by BadrIT (www.badrit.com) to investigate
On Sat, Nov 21, 2009 at 9:42 PM, Ahmed Eldawy <ahmed.eldawy@badrit.com>wrote:
[#351104] Removing optional white space — Philip Rhoades <phil@...>
People,
People,
People,
[#351119] Finding the closest value from a matrix — Mahadev Ittina <mittina@...>
I have a matrix that looks something like this
[#351121] COW-friendly Ruby 1.9? — David Masover <ninja@...>
Here's my test script:
[#351134] issues with Kernel#select — Tim Pease <tim.pease@...>
Waking up a thread that is waiting in Kernel#select does not appear to =
Tim Pease <tim.pease@gmail.com> wrote:
Tim Pease <tim.pease@gmail.com> wrote:
[#351136] All in one Ruby - HELP! — Guilherme Iscaro <belitos123@...>
Hey guys!
Guilherme Iscaro wrote:
THank you Marvin, you helped me a lot
[#351137] Order of evaluation and precedence — Seebs <usenet-nospam@...>
In _The Ruby Programming Language_, it is asserted that order of evaluation
Hi,
[#351154] How to match and count — Ruby Newbee <rubynewbee@...>
Hello,
On Nov 21, 8:00=A0pm, Ruby Newbee <rubynew...@gmail.com> wrote:
[#351158] really crazy about this (do/while) — Ruby Newbee <rubynewbee@...>
Hello,
[#351173] How to alias_method_chain initialize from a mixin. — Evan Senter <evansenter@...>
Hi,
[#351181] where to find the help document? — Ruby Newbee <rubynewbee@...>
Hello,
[#351194] OCR of PDF-documents using GData — Abigail Headroom <grape-1@...>
Hi,
[#351196] Pseudo array for Rails migration — Ralph Shnelvar <ralphs@...32.com>
Consider
On 22.11.2009 15:06, Ralph Shnelvar wrote:
RK> On 22.11.2009 15:06, Ralph Shnelvar wrote:
[#351212] Windows 7 can't install rails... — "Dale E. Moore" <daleemoore@...>
I'm sorry to be so ignorant, but; I can't seem to get started and learn
[#351245] More on psuedo arrays; Better way? — Ralph Shnelvar <ralphs@...32.com>
Newbie here:
Ralph Shnelvar wrote:
Marnen Laibow-Koser wrote:
BC> Marnen Laibow-Koser wrote:
Ralph Shnelvar wrote:
MLK> Do you know the difference between symbols and strings? A million
Ralph Shnelvar:
[#351257] How i can mage EXE file after write program — Sajjad Seyyed <treep_ir@...>
hi every body
if its possible please but here for me one program for make EXE file and
Sajjad Seyyed wrote:
[#351282] Best way to search through an array for an item matching a s — Daniel Webb <dan.m.webb@...>
Hi everyone,
Daniel Webb wrote:
Thanks Jeremy. That works a treat, however if I'm using an array
[#351297] ideas for a "parameter sweep" program? — Diego Virasoro <diego.virasoro@...>
Hello,
[#351303] how to use fxri — Taras <hi_tarasbulba@...>
hello,
[#351323] What is __FILE__ and $0? (newbie question) — Omar Campos <hypermeister@...>
Hello everyone,
[#351328] Warning: instance variable @foo not initialized — Seebs <usenet-nospam@...>
Running some simple tests with Prawn, I am getting thousands of lines
[#351331] autoloader, version 0.0.2 — David Masover <ninja@...>
A couple of handy features to enhance Kernel#autoload.
2009/11/24 David Masover <ninja@slaphack.com>:
[#351357] can't understand for String.delete — Ruby Newbee <rubynewbee@...>
Returns a copy of _str_ with all characters in the intersection of
[#351367] Difference between << and += for Strings and Arrays. Bug? — Pieter Hugo <pieter@...>
Hi
2009/11/24 Pieter Hugo <pieter@internext.co.za>:
Hi Guys
2009/11/24 Pieter Hugo <pieter@internext.co.za>:
Hi Robert (and everyone else) - thanks for the well reasoned responses.
[#351379] Where should I put my config file, and how to load it? — Ian Bridgeman <theadmiral@...>
Hello all!
[#351386] Help with each_with_index method — Chris Pelow <chris.pelow@...>
Hi there,
On Tue, Nov 24, 2009 at 12:00 PM, Chris Pelow <chris.pelow@gmail.com> wrote=
[#351400] DRb::DRbObject.alive? — Benoit Daloze <eregontp@...>
Hi,
[#351426] Ruby internals & other questions — Ralph Shnelvar <ralphs@...32.com>
Is there a document or website that describes how Ruby works?
Ralph Shnelvar wrote:
[#351448] Ruby a good choice for CGI? — Nick Dr <nickhannum@...>
Ive been messing around with Ruby for a few weeks now, and I'm fairly
On Wednesday 25 November 2009 01:12:19 pm Nick Dr wrote:
David Masover wrote:
On Wednesday 25 November 2009 02:38:32 pm Marnen Laibow-Koser wrote:
On Wed, Nov 25, 2009 at 12:52 PM, David Masover <ninja@slaphack.com> wrote:
On Wednesday 25 November 2009 03:00:49 pm Judson Lester wrote:
David Masover wrote:
On Wed, Nov 25, 2009 at 2:17 PM, Brian Candler <b.candler@pobox.com> wrote:
On Wednesday 25 November 2009 05:21:52 pm Judson Lester wrote:
[#351483] DRB class in array — Master Marv <marvin.mun@...>
hi,
[#351490] Heatmaps in Ruby — Marc Hoeppner <marc.hoeppner@...>
Hi,
[#351494] creating certificates and public and private keys — Adam Akhtar <adamtemporary@...>
Hi im going to have to create a lot of public and private keys for
In message <cac6f4ac7b83cbee671602c9a3e2fc6c@ruby-forum.com>, Adam
On 27 Nov 2009, at 11:01, Dave English wrote:
[#351502] Pattern match to fail if two periods in a row — Ralph Shnelvar <ralphs@...32.com>
Ok ... I really tried. And I used http://rubular.com/ (really nice)
[#351508] Ruby byte access to disk sectors like dd does — Gary Hasson <gary@...>
I have been unable to find any reference to Ruby methods that provide
On 28.11.2009 19:12, Bill Kelly wrote:
[#351509] Help with regex — Lucas Fialho <lucasfazprograma@...>
Hello everyone.
[#351530] Racc fails on install — Gordon Marsh <stumpz888@...>
Hi all,
[#351548] Class variables, instance variables, singleton; Ruby v. C++ — Ralph Shnelvar <ralphs@...32.com>
Newb here coming from C++
On Friday 27 November 2009 01:07:45 pm Ralph Shnelvar wrote:
DM> On Friday 27 November 2009 01:07:45 pm Ralph Shnelvar wrote:
Ralph Shnelvar wrote:
Hi --
DAB> And of course this is one of the (many) problems with class variables:
Ralph Shnelvar wrote:
>> (2) If I do the following
On Saturday 28 November 2009 08:43:30 am Ralph Shnelvar wrote:
DM> On Saturday 28 November 2009 08:43:30 am Ralph Shnelvar wrote:
Hi --
DAB> Many of us would not mourn them [@@ variables?] if they disappeared
Hi --
DAB> This is the so-called "class instance variable", which is really just
On Monday 30 November 2009 01:43:38 am Ralph Shnelvar wrote:
[#351559] Windows Pop Up — jackster the jackle <johnsheahan@...>
I don't normally run ruby scripts on my windows machine but in this
jackster the jackle wrote:
Thanks ALOT Marvin...that worked perfectly and saved me a ton of time.
[#351566] where is grep? — Ruby Newbee <rubynewbee@...>
Hello,
-----BEGIN PGP SIGNED MESSAGE-----
[#351572] Local variables can't be accessed from outside, right? — Michael Winterstein <parzival@...>
Hi, I've been trying to figure out metaprogramming and I've mostly got
[#351574] closures — Burlsm <charliesmith001@...>
hi
[#351587] SQLite and Ruby DLL problem — Omar Campos <hypermeister@...>
Hello all,
[#351596] iterate over a hash with values containing a array of hashes — Bruno Moura <brunormoura@...>
Hi
[#351607] app/helpers in Rails — T_P <tuo_pe@...>
Hello!
[#351622] Which server component? — Tim Bennen <mail@...>
Hello!
> The clients send the messages to the server witch JSON via a persistent
Thank you very much for your reply!
Tim Bennen wrote:
> I'm assuming here that the scaling you're looking for is large numbers
[#351629] What's the new hotness for packaging gems? — Tony Arcieri <tony@...>
I've used ad hoc stuff for packaging most of my gems. Long ago there was
> In this age of Gemcutter, what should I be using to generate my
[#351637] Best way to distribute an app — Omar Campos <hypermeister@...>
Hello everyone,
On Saturday 28 November 2009 09:03:12 pm Omar Campos wrote:
On Sunday 29 November 2009 02:33:01 pm Omar Campos wrote:
On Monday 30 November 2009 09:03:28 am Omar Campos wrote:
[#351639] Just found a round problem — Ruby Newbee <rubynewbee@...>
irb(main):026:0> 10.499999999999999.round
-----BEGIN PGP SIGNED MESSAGE-----
[#351655] ruby language parser in ruby — Brian Candler <b.candler@...>
I'm looking for a ruby language parser written in ruby, that I can hack
Brian Candler wrote:
On 11/30/09, Ryan Davis <ryand-ruby@zenspider.com> wrote:
A minor problem with the redparse gem is that it gives most of the files
Brian Candler wrote:
Marnen Laibow-Koser wrote:
> Was using ruby_parser, but now is also C... you know... ruby in ruby. :/
[#351664] semantics of @x v. $x — Ralph Shnelvar <ralphs@...32.com>
Newbie here:
[#351716] Oracle-oci8.2.0 — Vetrivel Vetrivel <vetrivel.bksys@...>
[#351722] How does ActiveRecord do it? — Ralph Shnelvar <ralphs@...32.com>
I know it sounds like a Rails question ... but it isn't.
On Mon, Nov 30, 2009 at 8:02 AM, Ralph Shnelvar <ralphs@dos32.com> wrote:
[#351735] Odd puts behaviour with REXML — David Sainte-claire <dsainteclaire@...>
Hello,
Morning David,
[#351753] have a problem with the loops and variable — Sajjad Po <magicc0d3r@...>
Hi Friends.
Michael Linfield wrote:
thank you friends.
I want create a program like this.
Sajjad Po wrote:
Michael Linfield wrote:
For something small such as testing lets say a million keys, the
Michael Linfield wrote:
>Not impressed with this explanation.
C++ GNU
Michael Linfield wrote:
Steve Wilhelm wrote:
[#351755] Problem trying to get a constant with correct scope — Alexandre Mutel <alexandre_mutel@...>
I'm trying to get a constant inside a class (but i have to do it outside
On Nov 30, 4:15=A0pm, Alexandre Mutel <alexandre_mu...@yahoo.fr> wrote:
On Nov 30, 6:10=A0pm, Alexandre Mutel <alexandre_mu...@yahoo.fr> wrote:
[#351765] Searching Text for Multiple Matches — jackster the jackle <johnsheahan@...>
I am using ruby to search and match text in a file that has several
Re: Newbie question: Defining a numeric type
Seebs wrote:
> On 2009-11-17, Marnen Laibow-Koser <marnen@marnen.org> wrote:
>> I didn't say the same object -- I said the same *thing*.
>> a = Stat.new(15, -2)
>> b = Stat.new(15, -2)
>> It doesn't matter in the slightest whether a.object_id == b.object_id.
>> Regardless, a and b are *the same thing* to all intents and purposes --
>> and you can tell that, in part, precisely because the object_id is
>> irrelevant.
>
> Perhaps, but (15, -2) and (14, -1) are also *equal*, even though they're
> obviously different things.
>
> Two fives equal a ten. When I am talking about money, all I care about
> is the net value, not the internal representation (coins or bills).
> Unless
> I have to deal with a vending machine.
>
> But 99% of the time, 10==10 is the correct interpretation of a
> comparison
> between two fives and a ten.
a = Cash.new(Array.new(2, Banknote.new(5, :usd)))
b = Cash.new([Banknote.new(10, :usd))
a.to_money = b.to_money
a.banknotes != b.banknotes
a ?== b # depends on your definition of equality.
>
>> call. You're confusing the method with its return value. The
>> difference is subtle but important.
>
> Hmm.
>
> Oh, heyyyyy.
>
> Okay, so one option would be:
> def str
> @str.to_i
> end
>
> In short, just return the value rather than the object I'm using to
> model
> it.
That would be the appropriate solution if you never wanted to expose the
Stat object.
>
> The problem is, I sort of want to be able to do things like:
> john.str.add_modifier("drunk", -3)
>
> Because really, the fact that str is a stat *is* part of the intended
> published interface.
Then your clients will know that it's a Stat object, and expect to call
to_i on it. I don't see anything wrong with that; you can overload Stat
+ Fixnum and so on as we discussed earlier in this thread.
But if you really want automatic, you can have it:
class Stat
def to_int
self.to_i
end
end
(According to http://www.rubyfleebie.com/to_i-vs-to_int/ , to_int is
called automatically as necessary and will make your class act as an
Integer. to_i, of course, will not do that.)
[...]
>> Why? There's no point to doing so as far as I can see. Even if it were
>> a Fixnum, it would already be yielding different objects every time it
>> changed. The client should make no assumptions about
>> john.strength.object_id.
>
> Not as a specified interface that people should rely on, but rather, as
> an
> implementation choice -- it seems crazy to me to regenerate whole
> object-trees
> frequently.
For your use case, you're probably right. For real value objects, it's
a different story.
>
>>> This sounds extremely expensive for an extremely commonplace thing. In
>>> an ordinary turn of a game, I might have thirty or forty modifiers which
>>> change, meaning that I'd be duplicating-but-modifying non-trivial object
>>> trees thirty or forty times.
>
>> It may sound expensive, but it really is the best way of handling value
>> objects. This is how classes like Fixnum, Date, and BigDecimal work.
>> (Actually, Fixnum uses the Flyweight pattern under the hood; the others
>> might also.)
>
> None of those classes are complicated trees containing five or ten or
> thirty other objects, though, are they?
Fixnum probably isn't. Date probably contains about 5 other objects
(totally guessing here -- haven't looked at the implementation). The
BigDecimal library I wrote for Rubinius contained about 3-5 other
objects, but I don't know if MRI or JRuby does it the same way. The
Address class I wrote for Quorum ( http://quorum2.sourceforge.net )
contains about 6 fields in an immutable value object. Of course, I
rarely only need to modify one field in someone's address.
>
>>> History of previous values (in some cases), and the modifiers aren't
>>> fixnums; they're name/value pairs
>
>> Really? You're not just doing
>> @modifiers = {:racial => 2, :class => 1, :armor => -1}?
>
> Modifier is a class too, which can handle things like counting down its
> duration, etcetera.
>
> And a stat has a handful of them.
OK...*these* are your value object candidates, perhaps.
>
>>> probably plus other traits such as
>>> a duration (some expire, some don't).
>
>> Does that really belong in the values itself? I'd tend to think not;
>> rather, that probably belongs in your event system.
>
> It seems to me that the knowledge that a modifier expires is best
> handled
> by embedding it in the modifier.
It might be.
>
>> But if you want history, then the StatValue object or whatever you wind
>> up using will probably have to be immutable anyway, so you can be sure
>> your history is accurate!
>
> Ahh, but I don't necessarily care whether it's accurate, just whether I
> have a record.
If it's not accurate, then there's no point keeping a record.
>
> For a concrete example: A lot of games would have, say, a strength
> stat,
> and things that can lower your strength. Then you find a "potion of
> restore strength", which restores your strength to its highest previous
> value.
>
> To my mind, this is the kind of thing that should be handled entirely
> by the stat object. It's not john's job to know what his highest score
> was for a given stat; it's the stat's job to know what its highest score
> was.
That depends. A good argument could be made for having the Character
store its own history, and just having the Stats be values.
In either case, though, for this sort of functionality you don't
necessarily need a full-fledged history. All you need is something like
class Stat
def value=(new_value)
@max_value = [new_value, @value].max
@value = new value
end
end
If you're ambitious, you could put together something like
ActiveRecord's before_save (which is probably what I'd use for this in a
Rails app).
>
>> Then refactor your design at that time. Design for what you have now,
>> rather than predicting the future. Remember YAGNI.
>
> In this case, though, I really do know that I need a fair bit of this.
> The ability to damage and restore stats is pretty much essential to a
> roguelike.
Well, then you'll run into the design issues when you're ready for them.
For now, though, and at every future step, try to
http://c2.com/cgi/wiki?DoTheSimplestThingThatCouldPossiblyWork -- that
is, work with the state of the app *at that time*. I know premature
generalization is tempting, but it's not usually a good idea.
>
>> Since you don't know yet, don't design yet for them (your future plans
>> could easily change). Design a model that works for what you actually
>> have, and be ready to change it as necessary.
>
> Yeah, but changing this into an immutable object is a lot MORE work. So
> I'm not sure I should put extra work into making the object less
> flexible
> on the off chance that I won't later not need to have done that work.
Right. It's now clear that your stat object is too complex to be a
simple immutable value object, although some of its components might
well be.
>
>> Largely correct, although I can think of exceptions. You'll probably
>> want to break this down into a composed object containing one or more
>> value objects.
>
> I think so.
>
>> No need. The former is a lot friendlier. You can always redefine
>> Character#strength= .
>
> True.
>
>> That strikes me as silly. There's no reason that the client class
>> should care whether your strength= method *really* does an assignment
>> operation.
>
> True.
>
> Hmm.
>
> So yeah, I think at this point, I really do want a complicated composite
> object, which happens to delegate to a value object which has traits
> which
> are useful for my purposes -- in this case, almost certainly a fixnum.
I don't think delegation will work here -- for one thing, you may not
need to store the total value in any actual instance variable. Using
to_int or possibly coerce will work much better.
>
> -s
Best,
--
Marnen Laibow-Koser
http://www.marnen.org
marnen@marnen.org
--
Posted via http://www.ruby-forum.com/.