I'd be particularly happy if we could get more 3-10 minute talks that
quickly and casually showcase a method, tool, library or coding
technique. However, if you have a larger talk, it's welcome too.
See you soon!
-igal
###
View map to venue and add the vent to your calendar:
http://calagator.org/events/1250458118
ABOUT: The Portland Ruby Brigade is a user group for Ruby programmers in
the Portland Oregon area. Join other developers for presentations and
discussions about Ruby and its uses.
VENUE: This meeting’s space is kindly provided by Robert Half Technology
at their 2nd Floor Conference Room. Enter the KOIN Tower from SW
Columbia between 2nd and 3rd Avenue, take the back elevators to the 2nd
floor, and then follow the pdxruby signs.
If you're into trying out multiple Ruby implementations, you might find this a useful tool.
-- Monty
> --
> You received this message because you are subscribed to the Google Groups "pdxruby" group.
> To post to this group, send email to pdx...@googlegroups.com.
> To unsubscribe from this group, send email to pdxruby+u...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/pdxruby?hl=en.
>
On Jan 30, 2010, at 17:03, Monty Williams <monty.w...@gmail.com>
wrote:
-Chuck
I Wish I was going to be around for this one.
--Bob
>
> Sent from my iPhone
>
> On Jan 30, 2010, at 6:46 PM, Andrew Kurtz <andrew.h...@gmail.com
> <mailto:andrew.h...@gmail.com>> wrote:
>
>> Isn't that multiruby that does that?
>>
>> On Sat, Jan 30, 2010 at 6:24 PM, Chuck Vose <vos...@gmail.com
>> <mailto:vos...@gmail.com>> wrote:
>>
>> I second this! I've always heard that there was a feature that allows
>> you to run your test suite or some code on a bunch of different
>> revisions but I've never been able to set it up right. Would you be
>> able to cover that?
>>
>> -Chuck
>>
>> On Sat, Jan 30, 2010 at 6:09 PM, Jerry Hilts <gwh...@gmail.com
>> <mailto:gwh...@gmail.com>> wrote:
>> >
>> > I for one would be very interested.
>> >
>> >
>> > On Jan 30, 2010, at 17:03, Monty Williams
>> >>> VENUE: This meeting�s space is kindly provided by Robert Half
>> Technology
>> >>> at their 2nd Floor Conference Room. Enter the KOIN Tower from SW
>> >>> Columbia between 2nd and 3rd Avenue, take the back elevators
>> to the 2nd
>> >>> floor, and then follow the pdxruby signs.
>> >>>
>> >>>
>> >>> --
>> >>> You received this message because you are subscribed to the
>> Google Groups
>> >>> "pdxruby" group.
>> >>> To post to this group, send email to pdx...@googlegroups.com
>> <mailto:pdx...@googlegroups.com>.
>> >>> To unsubscribe from this group, send email to
>> >>> pdxruby+u...@googlegroups.com
>> <mailto:pdxruby+u...@googlegroups.com>.
>> >>> For more options, visit this group at
>> >>> http://groups.google.com/group/pdxruby?hl=en.
>> >>>
>> >>
>> >> --
>> >> You received this message because you are subscribed to the
>> Google Groups
>> >> "pdxruby" group.
>> >> To post to this group, send email to pdx...@googlegroups.com
>> <mailto:pdx...@googlegroups.com>.
>> >> To unsubscribe from this group, send email to
>> >> pdxruby+u...@googlegroups.com
>> <mailto:pdxruby+u...@googlegroups.com>.
>> >> For more options, visit this group at
>> >> http://groups.google.com/group/pdxruby?hl=en.
>> >>
>> >
>> > --
>> > You received this message because you are subscribed to the
>> Google Groups
>> > "pdxruby" group.
>> > To post to this group, send email to pdx...@googlegroups.com
>> <mailto:pdx...@googlegroups.com>.
>> > To unsubscribe from this group, send email to
>> > pdxruby+u...@googlegroups.com
>> <mailto:pdxruby+u...@googlegroups.com>.
>> > For more options, visit this group at
>> > http://groups.google.com/group/pdxruby?hl=en.
>> >
>> >
>>
>> --
>> You received this message because you are subscribed to the
>> Google Groups "pdxruby" group.
>> To post to this group, send email to pdx...@googlegroups.com
>> <mailto:pdx...@googlegroups.com>.
>> To unsubscribe from this group, send email to
>> pdxruby+u...@googlegroups.com
>> <mailto:pdxruby+u...@googlegroups.com>.
>> For more options, visit this group at
>> http://groups.google.com/group/pdxruby?hl=en.
>>
>>
>> --
>> You received this message because you are subscribed to the Google
>> Groups "pdxruby" group.
>> To post to this group, send email to pdx...@googlegroups.com
>> <mailto:pdx...@googlegroups.com>.
>> To unsubscribe from this group, send email to
>> pdxruby+u...@googlegroups.com
>> <mailto:pdxruby+u...@googlegroups.com>.
It's widely known that "everybody remembers their first time" though
most published sources are a little vague on what exact experience
this is referring to. Your first kiss, perhaps, or maybe your first
fumbling attempts at illicit late night metaprogramming.
Or maybe your first constant assignment. Some objects, certainly,
remember this vividly. Specifically, they remember the name of the
first constant they were ever assigned into.
The code for creating such objects looks like this:
def constant_watcher
result = ______
def result.first_constant_I_was_in
______
end
def result.to_s
first_constant_I_was_in.empty? ? "<virgin>" : "My first was
#{first_constant_I_was_in}"
end
result
end
The to_s method is just added to simplify the exploration of these
object's properties, as demonstrated in this little irb session, so we
don't have to keep calling first_constant_I_was_in (commentary on
### lines):
>> require "hangman_valentine.rb"
=> true
### Here we set the local variable a to an object produced by the
function constant_watcher
### Since a has never been held by a constant, it is a <virgin>
###
>> a = constant_watcher
=> <virgin>
>> a
=> <virgin>
### Putting a in another variable doesn't affect this
>> x = a
=> <virgin>
### But putting it in a constant! Oh, it will never forget that.
Note also that
### x still refers to the same object as a and Foo do.
>> Foo = a
=> My first was Foo
>> a
=> My first was Foo
>> x
=> My first was Foo
### Note that only the first constant is thus immortalized; if a is
subsequently held by other
### constants they aren't remembered.
>> Goo = a
=> My first was Foo
### Also note that this exclusivity isn't symmetrical; if (shocking,
but it happens) the
### same constant subsequently holds another of these objects they
will both remember
### it as their first, but they aren't the same object.
>> Foo = constant_watcher
(irb):21: warning: already initialized constant Foo
=> My first was Foo
>> a
=> My first was Foo
>> a === Foo
=> false
### We can create as many of these as we like; they are independent
###
>> b = (0..9).collect { constant_watcher }
=> [<virgin>, <virgin>, <virgin>, <virgin>, <virgin>, <virgin>,
<virgin>, <virgin>, <virgin>, <virgin>]
>> X = b[3]
=> My first was X
>> b
=> [<virgin>, <virgin>, <virgin>, My first was X, <virgin>, <virgin>,
<virgin>, <virgin>, <virgin>, <virgin>]
>> $q = b[7]
=> <virgin>
>> b
=> [<virgin>, <virgin>, <virgin>, My first was X, <virgin>, <virgin>,
<virgin>, <virgin>, <virgin>, <virgin>]
>> module Badabing
>> Badaboom = $q
>> end
=> My first was Badabing::Badaboom
>> b
=> [<virgin>, <virgin>, <virgin>, My first was X, <virgin>, <virgin>,
<virgin>, My first was Badabing::Badaboom, <virgin>, <virgin>]
Happy valentines day!
-- Markus
P.S. At 12 blanks I hope that this is near the sweet spot of short
enough to hold interest yet not amenable to brute force.
I haven't been to a PDX.rb meeting in a while - what's up for tonight?
Anybody want to do a brief report on the Rails projects associated
with CrisisCamp? All I know is the names and a rough idea of who the
participants are. Since I'm not a Rails person, my own contributions
have been peripheral at best (some Twitter lexical analysis,
PostgreSQL DBA, Perl and Ruby data collection code).