简体   繁体   中英

How to skip JSLint goal in the maven build?

I want to set up a maven javascript project using the maven-javascript-plugin. This works fine until now, but now I added the DOJO toolkit in the compressed version. When I start the build process the DOJO toolkit does not pass the jslint test and the build process is stopped.

Can someone tell my how to skip the jslint goal in the build?

Thank you!

You should be able to configure the jslint-plugin and use the "excludes" param of "jslint:jslint" .

You may need to completely specify the jslint plugin configuration ; I have not confirmed this.

Perhaps not so well suited for the question itself, but if one wants to completely disable jslint , the option can be to bind it to unexisting phases:

<build>
    <pluginManagement>
        <!-- Disable jslint for all phases -->
        <plugins>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>jslint-maven-plugin</artifactId>
                <executions>
                    <execution>
                        <id>default-jslint</id>
                        <phase>process-sources-unbind</phase>
                    </execution>
                    <execution>
                        <id>default-test-jslint</id>
                        <phase>process-test-sources-unbind</phase>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </pluginManagement>
</build>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM