From 33a2e1965e81a75d06a3845c3880c23b0ae642b5 Mon Sep 17 00:00:00 2001 From: "ruben.boada" Date: Mon, 14 Oct 2024 13:03:15 +0200 Subject: [PATCH] Add option to skip the maven plugin execution --- .../java/io/airlift/drift/maven/IdlGeneratorMojo.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/drift-maven-plugin/src/main/java/io/airlift/drift/maven/IdlGeneratorMojo.java b/drift-maven-plugin/src/main/java/io/airlift/drift/maven/IdlGeneratorMojo.java index 0a434b32a..a792e4795 100644 --- a/drift-maven-plugin/src/main/java/io/airlift/drift/maven/IdlGeneratorMojo.java +++ b/drift-maven-plugin/src/main/java/io/airlift/drift/maven/IdlGeneratorMojo.java @@ -100,10 +100,18 @@ public class IdlGeneratorMojo @Parameter private boolean quiet; + @Parameter(property = "drift.skip", defaultValue = "false") + private boolean skip; + @Override public void execute() throws MojoExecutionException { + if (skip) { + getLog().info("Drift IDL generation is skipped."); + return; + } + ClassLoader classLoader = createClassLoaderFromCompileTimeDependencies(); ThriftIdlGeneratorConfig config = ThriftIdlGeneratorConfig.builder()