Sorry, I should have jumped on this earlier: When I said 'template', I wasn't talking about a template for new files, I was talking about a 'code formatting' template specific to the IDE. That is, you can configure the source formatting rules and export it as a template that other IDEs could import to ensure everyone is using the same formatting rules.
A file template of what goes where in the file (constants vs constructors vs mutators, etc) is a different case. But I do believe that we should also have such a file template that is defined in the wiki that people can use when creating new classes. In fact, that wiki page should probably have as attachments the IDE-specific file templates that can be imported depending on the IDE you use. And I think it would be nice to have Jalopy or Checkstyle integrated in the build to use as a gut check before you commit... Cheers, Les On Mon, Jan 19, 2009 at 3:47 PM, Daniel J. Lauk <[email protected]>wrote: > If I may add my two cents: > No offence meant, but IMHO you'd be way better of if you'd not use > templates for new files, but instead enforce a common coding style > through a source code pretty printer and share the syntax rule file > for that. > Then always before committing to the central repository you could run > the code through that to get lost of developer specific favourite > formattings etc. > Also every developer can have their own little variations for their > convenience and still commit in the same format. > > Cheers, > DJ > > 2009/1/19 Emmanuel Lecharny <[email protected]>: > > On Mon, Jan 19, 2009 at 5:49 PM, Les Hazlewood <[email protected]> > wrote: > >> Hi Emmanuel, > >> > >> We haven't really specified a formal standard per se, but you're right, > it > >> is essentially nearly identical to Sun's. Prior to joining the ASF > >> Incubator, most of us (all of us?) used IntelliJ IDEA and just used its > >> default formatting template, which is Sun's. > > > > That's all good. If you were to use some specific template (and I > > think that, at some point, this is necessary), then you would have to > > create the formatting for IDE used by the team, and describe what has > > been changed from sun's standard. > > > > Typically, but this is more about template than formatting, being able > > to create a class with the ASF header automatically injecteed, plus > > the @author tag created, that's a way to remain consistent and will > > make Rat happy. > > > > Then, inject those templates into subversion (here, this is a > > different matter than the .project or .classpath, as it's not > > something any build tool can generate). > > > > > > Thanks ! > > > > -- > > Regards, > > Cordialement, > > Emmanuel Lécharny > > www.iktek.com > > >
