From: dblack@... Date: 2006-11-15T01:01:58+09:00 Subject: Re: ruby indentantion Hi -- On Wed, 15 Nov 2006, Alfonso wrote: > I have just started with ruby, and something that I have observed is that > most of the code is indented with 2 spaces. Having programmed some time with > C# and python, it's very strange to me so few identation. To me 4 spaces is > much better to read. Is there something like a style guide in ruby that says > that you should use 2 spaces or is it all right using 4 or 3 spaces? What do > you use in your code? I use 2 spaces, which is the Ruby tradition and custom. I don't think there's anything in the standard library that does otherwise. Whatever language I'm using, I don't like to have my code look like David Black code, but rather like anonymous, standard, boring code that uses the most common stylistic conventions for that language. If you're more into making a statement about your own sense of style, you can indent more :-) David -- David A. Black | dblack@rubypal.com Author of "Ruby for Rails" [1] | Ruby/Rails training & consultancy [3] DABlog (DAB's Weblog) [2] | Co-director, Ruby Central, Inc. [4] [1] http://www.manning.com/black | [3] http://www.rubypowerandlight.com [2] http://dablog.rubypal.com | [4] http://www.rubycentral.org