From: Josh Cheek Date: 2010-01-11T21:51:20+09:00 Subject: Re: Ruby editing style rules and recommendation? --000e0cd1391e324522047ce2febb Content-Type: text/plain; charset=ISO-8859-1 On Mon, Jan 11, 2010 at 12:49 AM, Albert Schlef wrote: > Why? > > It makes it conspicuous where everything begins and ends, you don't have to analyze anything to figure it out. > How would you usually add one level of nesting there? (perhaps I could > learn an editing trick.) > > I don't think I understand the question, you write it the same way you normally would, you just replace some do/end with brackets, where they make it easier to follow. The criteria are subjective. I'm not sure what you mean by an editing trick, presumably you're thinking as Marnen did, that adding a level obligates me to swap anything back and forth. I don't consider that to be the case, it's not a rule, it's just something I do to clarify my code, sometimes I find two do/end pairs between every bracket is easiest to read, it just depends. But if you're in TextMate, you can do ctrl+{ to swap back and forth. It seems to work okay, but is a little buggy, so I don't use it often. --000e0cd1391e324522047ce2febb--