You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by da...@apache.org on 2020/11/25 09:25:19 UTC

[sling-slingfeature-maven-plugin] branch master updated: Make feature provider overridable

This is an automated email from the ASF dual-hosted git repository.

davidb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-slingfeature-maven-plugin.git


The following commit(s) were added to refs/heads/master by this push:
     new e8c2031  Make feature provider overridable
e8c2031 is described below

commit e8c2031c1b76153e6e773a37a422f43d4bb5475d
Author: David Bosschaert <da...@apache.org>
AuthorDate: Wed Nov 25 09:20:53 2020 +0000

    Make feature provider overridable
---
 .../org/apache/sling/feature/maven/mojos/AnalyseFeaturesMojo.java   | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/src/main/java/org/apache/sling/feature/maven/mojos/AnalyseFeaturesMojo.java b/src/main/java/org/apache/sling/feature/maven/mojos/AnalyseFeaturesMojo.java
index 93699ba..afa769b 100644
--- a/src/main/java/org/apache/sling/feature/maven/mojos/AnalyseFeaturesMojo.java
+++ b/src/main/java/org/apache/sling/feature/maven/mojos/AnalyseFeaturesMojo.java
@@ -104,7 +104,7 @@ public class AnalyseFeaturesMojo extends AbstractIncludingFeatureMojo {
         }
         getLog().debug(MessageUtils.buffer().strong("Scanner").a(" successfully set up").toString());
 
-        FeatureProvider featureProvider = new BaseFeatureProvider();
+        FeatureProvider featureProvider = getFeatureProvider();
 
         boolean hasErrors = false;
         for (final Scan an : list) {
@@ -209,6 +209,10 @@ public class AnalyseFeaturesMojo extends AbstractIncludingFeatureMojo {
         };
     }
 
+    protected BaseFeatureProvider getFeatureProvider() {
+        return new BaseFeatureProvider();
+    }
+
     void addTaskConfigurationDefaults(Map<String, Map<String, String>> taskConfiguration) {
         String featureModelFileStorage = project.getBuild().getDirectory() + "/sling-slingfeature-maven-plugin-fmtmp";
         Map<String, String> wildCardCfg = taskConfiguration.get(ANALYSER_CONFIG_WILDCARD);