[dojo-contributors] A new build tool for style guide violation checking

Shane O'Sullivan shaneosullivan1 at gmail.com
Mon May 11 10:57:13 EDT 2009


I think keeping it simple for developers to use is quite worthwhile.
Also, while the errors being checked for can conceptually be grouped
into separate "types" of validation,  they all fall under the Dojo
style guide, and are all simple little things that developers can fix
quickly.  Having them all checked for, and listed, in the same place
makes sense to me.

Pete, with regards to your suggestions for || and && surrounded by
spaces, that's been added and the patch updated.  The page at
http://skynet.ie/~sos/misc/dojoCheckstyle/util/buildscripts/checkstyleReport.html
has also been updated with the new errors, now at a grand total of
6011.

Thanks

Shane

2009/5/11 Mike Wilcox <mwilcox at sitepen.com>:
>
>> Mike Wilcox wrote:
>>> It sounds like you are mixing two different validations - code
>>> integrity (braces in if statements)  and formating integrity (proper
>>> tabbing and minimum whitespace).
>>>
>> Maybe I'm confused, but I'm talking about our "style guidelines".
>>
>> if (foo) { return; }
>>
>> should be:
>>
>> if(foo){ return; }
>>
>> and explicitly NOT:
>>
>> if(foo) return;
>
> Yes, but let me clarify what I saw as a problem - having the parser
> handle code validation and format validation. If hypothetically, we
> wanted to use JSLint, and remove our custom engine we would lose the
> validation of tabs and spaces, since JSLint doesn't do that.
>
> Basically, there is code style which applies to JavaScript, and format
> style which applies to the docs and build/compression.
>
> I only suggest they be two different validation engines. Otherwise its
> all good stuff.
>
>
> Mike
>
> _______________________________________________
> dojo-contributors mailing list
> dojo-contributors at mail.dojotoolkit.org
> http://mail.dojotoolkit.org/mailman/listinfo/dojo-contributors
>


More information about the dojo-contributors mailing list