http://www.perlmonks.org?node_id=490294


in reply to Re^4: My coding guidelines
in thread My coding guidelines

The best solution to this controversy is to use perltidy. Just filter that nasty code through perltidy to get your preferred indentation, brace location, else-cuddledness, etc. If you are working in a team project, have the team define a standard set of perltidy options that are to be used before checking the code in. It can be automated as part of the check-in process so that you don't have to worry about it.

Replies are listed 'Best First'.
Re^6: My coding guidelines
by emazep (Priest) on Sep 08, 2005 at 21:21 UTC
    The best solution to this controversy is to use perltidy.
    This is a good advice, except that then again you have to decide if you want to use tabs or spaces for indentation, when it comes to tell perltidy about it ;-) (through the options -et and/or -t).

    I'm realizing that people are scared about tabs (even the perltidy docs recommend against it) because they think that problems may arise if not everyone is using the same number of spaces to display tabs in their editors, while few seem to realize that permitting each user to display the tabs the way she prefer is just the great advantage here.

    Tabs will let the user to freely decide how many spaces to display for indentation, at the sime time granting the other users the same freedom.

    Ciao,
    Emanuele.

      Seconded.


      Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
      Lingua non convalesco, consenesco et abolesco. -- Rule 1 has a caveat! -- Who broke the cabal?
      "Science is about questioning the status quo. Questioning authority".
      The "good enough" maybe good enough for the now, and perfection maybe unobtainable, but that should not preclude us from striving for perfection, when time, circumstance or desire allow.