Rick DeNatale <rick.denatale / gmail.com> writes: > On Sun, Apr 26, 2009 at 6:48 PM, James Gray <james / grayproductions.net> wrote: >> I hate to be the guy to start another { … } vs. do … end thread, but I have >> some questions I would love to hear opinions on. >> >> I use to just use the rule of { … } for one-liners and do … end for the >> longer stuff. However, I've recently switched to trying out { … } for the >> times when I care about the return value and do … end for the times the >> block is for side effects. For the most part, I do like the new strategy, >> but sometimes I have trouble deciding which to use. > > Well, I went back to what I wrote over a year ago on this > "controversy" and I think it stands up pretty well. > > http://talklikeaduck.denhaven2.com/2007/10/02/ruby-blocks-do-or-brace FYI - looks like you have an extra trailing paren here in the last code example: description 'pickup up the leaves' task(:rake => pre_raking_tasks) {#code to rake the leaves}) BTW - this is one of the reasons I tend to use parens on function invocations consistently. -- Brian Adkins http://lojic.com/