From 2d63c03af1908b3b5d8f9181a3deca70fda3747b Mon Sep 17 00:00:00 2001 From: Slawomir Jaranowski Date: Sun, 19 Nov 2023 17:57:12 +0100 Subject: [PATCH] Rename Mojo parameters for skip --- src/it/add-resource-skip/pom.xml | 2 +- src/it/add-resource-skip/verify.groovy | 2 +- src/it/add-source-skip/pom.xml | 2 +- src/it/add-source-skip/verify.groovy | 2 +- src/it/add-test-resource-skip/pom.xml | 2 +- src/it/add-test-resource-skip/verify.groovy | 2 +- src/it/add-test-source-skip/pom.xml | 2 +- src/it/add-test-source-skip/verify.groovy | 2 +- .../java/org/codehaus/mojo/buildhelper/AddResourceMojo.java | 4 ++-- .../java/org/codehaus/mojo/buildhelper/AddSourceMojo.java | 4 ++-- .../org/codehaus/mojo/buildhelper/AddTestResourceMojo.java | 4 ++-- .../java/org/codehaus/mojo/buildhelper/AddTestSourceMojo.java | 4 ++-- 12 files changed, 16 insertions(+), 16 deletions(-) diff --git a/src/it/add-resource-skip/pom.xml b/src/it/add-resource-skip/pom.xml index a9364055..c7111b82 100644 --- a/src/it/add-resource-skip/pom.xml +++ b/src/it/add-resource-skip/pom.xml @@ -26,7 +26,7 @@ does-not-matter - true + true diff --git a/src/it/add-resource-skip/verify.groovy b/src/it/add-resource-skip/verify.groovy index f69011e0..2478f0d7 100644 --- a/src/it/add-resource-skip/verify.groovy +++ b/src/it/add-resource-skip/verify.groovy @@ -3,7 +3,7 @@ assert file.exists(); String text = file.getText("utf-8"); -assert text.contains("skip = true"); +assert text.contains("skipAddResource = true"); assert text.contains("Skipping plugin execution!"); return true; diff --git a/src/it/add-source-skip/pom.xml b/src/it/add-source-skip/pom.xml index d0034f6c..78d8083f 100644 --- a/src/it/add-source-skip/pom.xml +++ b/src/it/add-source-skip/pom.xml @@ -23,7 +23,7 @@ ${project.basedir}/not-existing - true + true diff --git a/src/it/add-source-skip/verify.groovy b/src/it/add-source-skip/verify.groovy index f69011e0..b8ef38bb 100644 --- a/src/it/add-source-skip/verify.groovy +++ b/src/it/add-source-skip/verify.groovy @@ -3,7 +3,7 @@ assert file.exists(); String text = file.getText("utf-8"); -assert text.contains("skip = true"); +assert text.contains("skipAddSource = true"); assert text.contains("Skipping plugin execution!"); return true; diff --git a/src/it/add-test-resource-skip/pom.xml b/src/it/add-test-resource-skip/pom.xml index dbb7a22d..48a17fdd 100644 --- a/src/it/add-test-resource-skip/pom.xml +++ b/src/it/add-test-resource-skip/pom.xml @@ -26,7 +26,7 @@ does-not-matter - true + true diff --git a/src/it/add-test-resource-skip/verify.groovy b/src/it/add-test-resource-skip/verify.groovy index f69011e0..0bed2b5f 100644 --- a/src/it/add-test-resource-skip/verify.groovy +++ b/src/it/add-test-resource-skip/verify.groovy @@ -3,7 +3,7 @@ assert file.exists(); String text = file.getText("utf-8"); -assert text.contains("skip = true"); +assert text.contains("skipAddTestResource = true"); assert text.contains("Skipping plugin execution!"); return true; diff --git a/src/it/add-test-source-skip/pom.xml b/src/it/add-test-source-skip/pom.xml index 3054df5e..26bbb2a8 100644 --- a/src/it/add-test-source-skip/pom.xml +++ b/src/it/add-test-source-skip/pom.xml @@ -23,7 +23,7 @@ ${project.basedir}/not-existing - true + true diff --git a/src/it/add-test-source-skip/verify.groovy b/src/it/add-test-source-skip/verify.groovy index f69011e0..c0c7780a 100644 --- a/src/it/add-test-source-skip/verify.groovy +++ b/src/it/add-test-source-skip/verify.groovy @@ -3,7 +3,7 @@ assert file.exists(); String text = file.getText("utf-8"); -assert text.contains("skip = true"); +assert text.contains("skipAddTestSource = true"); assert text.contains("Skipping plugin execution!"); return true; diff --git a/src/main/java/org/codehaus/mojo/buildhelper/AddResourceMojo.java b/src/main/java/org/codehaus/mojo/buildhelper/AddResourceMojo.java index 68b9e2a1..f4129233 100644 --- a/src/main/java/org/codehaus/mojo/buildhelper/AddResourceMojo.java +++ b/src/main/java/org/codehaus/mojo/buildhelper/AddResourceMojo.java @@ -44,7 +44,7 @@ public class AddResourceMojo extends AbstractAddResourceMojo { * @since 3.5.0 */ @Parameter(property = "buildhelper.addresource.skip", defaultValue = "false") - private boolean skip; + private boolean skipAddResource; public void addResource(Resource resource) { getProject().addResource(resource); @@ -54,6 +54,6 @@ public void addResource(Resource resource) { } protected boolean isSkip() { - return skip; + return skipAddResource; } } diff --git a/src/main/java/org/codehaus/mojo/buildhelper/AddSourceMojo.java b/src/main/java/org/codehaus/mojo/buildhelper/AddSourceMojo.java index 5f10f3bc..5198b8b7 100644 --- a/src/main/java/org/codehaus/mojo/buildhelper/AddSourceMojo.java +++ b/src/main/java/org/codehaus/mojo/buildhelper/AddSourceMojo.java @@ -60,10 +60,10 @@ public class AddSourceMojo extends AbstractMojo { * @since 3.5.0 */ @Parameter(property = "buildhelper.addsource.skip", defaultValue = "false") - private boolean skip; + private boolean skipAddSource; public void execute() { - if (skip) { + if (skipAddSource) { if (getLog().isInfoEnabled()) { getLog().info("Skipping plugin execution!"); } diff --git a/src/main/java/org/codehaus/mojo/buildhelper/AddTestResourceMojo.java b/src/main/java/org/codehaus/mojo/buildhelper/AddTestResourceMojo.java index 497b670e..a1000caf 100644 --- a/src/main/java/org/codehaus/mojo/buildhelper/AddTestResourceMojo.java +++ b/src/main/java/org/codehaus/mojo/buildhelper/AddTestResourceMojo.java @@ -44,7 +44,7 @@ public class AddTestResourceMojo extends AbstractAddResourceMojo { * @since 3.5.0 */ @Parameter(property = "buildhelper.addtestresource.skip", defaultValue = "false") - private boolean skip; + private boolean skipAddTestResource; /** * Add the resource to the project. @@ -60,6 +60,6 @@ public void addResource(Resource resource) { @Override protected boolean isSkip() { - return skip; + return skipAddTestResource; } } diff --git a/src/main/java/org/codehaus/mojo/buildhelper/AddTestSourceMojo.java b/src/main/java/org/codehaus/mojo/buildhelper/AddTestSourceMojo.java index 23fe2635..f79638c2 100644 --- a/src/main/java/org/codehaus/mojo/buildhelper/AddTestSourceMojo.java +++ b/src/main/java/org/codehaus/mojo/buildhelper/AddTestSourceMojo.java @@ -60,10 +60,10 @@ public class AddTestSourceMojo extends AbstractMojo { * @since 3.5.0 */ @Parameter(property = "buildhelper.addtestsource.skip", defaultValue = "false") - private boolean skip; + private boolean skipAddTestSource; public void execute() { - if (skip) { + if (skipAddTestSource) { if (getLog().isInfoEnabled()) { getLog().info("Skipping plugin execution!"); }