Skip to content

Commit

Permalink
Merge pull request #108 from knoxg/issue-104-skip-flag
Browse files Browse the repository at this point in the history
issue-104: skipJspc property (4.x branch)
  • Loading branch information
leonardehrenfried authored Dec 20, 2022
2 parents 35649ca + 1fb6c70 commit 4ccdee0
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/main/java/io/leonard/maven/plugins/jspc/JspcMojo.java
Original file line number Diff line number Diff line change
Expand Up @@ -284,6 +284,12 @@ public class JspcMojo extends AbstractMojo {
*/
@Parameter(defaultValue = "true")
private boolean strictQuoteEscaping;

/**
* Set this to 'true' to bypass compilation of JSP sources.
*/
@Parameter(defaultValue = "false", property = "jspc.skip")
private boolean skip;

private Map<String, NameEnvironmentAnswer> resourcesCache = new ConcurrentHashMap<>();

Expand Down Expand Up @@ -313,7 +319,12 @@ public void execute() throws MojoExecutionException, MojoFailureException {
getLog().info("compilerVersion=" + compilerVersion);
getLog().info("compilerClass=" + compilerClass);
getLog().info("strictQuoteEscaping=" + strictQuoteEscaping);
getLog().info("skip=" + skip);
}
if ( skip ) {
getLog().info( "Not compiling jsp sources" );
return;
}
try {
long start = System.currentTimeMillis();

Expand Down Expand Up @@ -738,3 +749,4 @@ private String getwebXmlFragmentFilename(int threadIndex) {
return threads == 1 ? webXmlFragment : webXmlFragment + "." + threadIndex;
}
}

0 comments on commit 4ccdee0

Please sign in to comment.