[ 
http://jira.codehaus.org/browse/MJS-14?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=259672#action_259672
 ] 

Lei Wang commented on MJS-14:
-----------------------------

I created and attached the patch files for this.

> Ways to exclude script files during JS Lint report generation
> -------------------------------------------------------------
>
>                 Key: MJS-14
>                 URL: http://jira.codehaus.org/browse/MJS-14
>             Project: Maven Javascript Tools
>          Issue Type: Improvement
>         Environment: "javascript-report-maven-plugin" 
>            Reporter: Saravanan Kathiresan
>            Assignee: Tim Astle
>             Fix For: 1.0
>
>         Attachments: MJS-14 AbstractJavascriptReport.java.patch, MJS-14 
> JsLintReport.java.patch
>
>
> When tried to generate JS Lint report we got null pointer exception for few 
> JS files which we really dont want the JS Lint report. We tried to exclude 
> few files for JS Lint report but there is no provision to do it. I have 
> modified the files as 
> org.codehaus.mojo.javascript.AbstractJavascriptReport.java 
> protected String[] getScripts( File sourceDirectory, String[] excludes )
>     {
>         DirectoryScanner scanner = new DirectoryScanner();
>         scanner.setBasedir( sourceDirectory );
>         if(excludes!=null && excludes.length >0)
>         {
>               scanner.setExcludes(excludes); 
>         }
>         else
>         {
>               scanner.addDefaultExcludes();
>         }
>         scanner.setIncludes( new String[] { "**/*.js" } );
>         scanner.scan();
>         return scanner.getIncludedFiles();
>     }
> org.codehaus.mojo.javascript.JsLintReport.java
> String[] scripts = getScripts( sourceDirectory, excludes ); //Where Excludes 
> gets the value from the pom.xml
> It works well and we have implemented it in our project. It would be better 
> to add this to the standard release
> Thanks
> Sara

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to