schaefa commented on a change in pull request #49: Replacement PR for #41 with
a clean set of changes
URL:
https://github.com/apache/sling-slingfeature-maven-plugin/pull/49#discussion_r379164795
##########
File path:
src/main/java/org/apache/sling/feature/maven/mojos/IncludeArtifactMojo.java
##########
@@ -90,12 +138,29 @@ public void execute() throws MojoExecutionException,
MojoFailureException {
ProjectHelper.getFeatures(this.project).put(key, found);
ProjectHelper.getAssembledFeatures(this.project).put(key, found);
}
+ getLog().debug("Found Feature: " + found + ", artifact: " + art);
includeArtifact(found, includeArtifactExtension, art);
+ getLog().debug("Feature Key: " + key + ", feature from key: " +
ProjectHelper.getAssembledFeatures(this.project).get(key));
includeArtifact(ProjectHelper.getAssembledFeatures(this.project).get(key),
includeArtifactExtension,
art.copy(art.getId()));
+
+ addDependencies(found);
+
+ // Obtain any features from Source folder and add any Extensions to
the target feature
+ final FeatureSelectionConfig featureSelectionConfig = new
FeatureSelectionConfig();
+ featureSelectionConfig.setFilesInclude("**/*.json" );
+ if(file != null) {
+ featureSelectionConfig.setFilesExclude("**/" + file.getName());
+ }
+ final Map<String, Feature> selection =
this.getSelectedFeatures(featureSelectionConfig);
+
+ includeFeatures(selection, found);
+
+ // Write the Feature into its file and install it
if (file != null) {
try ( final Writer writer = new FileWriter(file)) {
FeatureJSONWriter.write(writer, found);
+ installFMDescriptor(file, found);
Review comment:
After some back and forth I was able to install the FM using the Attach
Features Mojo and so I am going to remove this.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services