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

sseifert pushed a commit to branch feature/SLING-13081-error-message-output
in repository 
https://gitbox.apache.org/repos/asf/sling-slingfeature-maven-plugin.git

commit ec22bad03baa638c2b81bca1cf8b30f2b33adbe5
Author: Stefan Seifert <[email protected]>
AuthorDate: Thu Jan 29 10:43:34 2026 +0100

    SLING-13081 Improve error message when providing incomplete includea 
artifact configuration
---
 .../apache/sling/feature/maven/mojos/FeatureSelectionConfig.java  | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git 
a/src/main/java/org/apache/sling/feature/maven/mojos/FeatureSelectionConfig.java
 
b/src/main/java/org/apache/sling/feature/maven/mojos/FeatureSelectionConfig.java
index 131eddd..46494eb 100644
--- 
a/src/main/java/org/apache/sling/feature/maven/mojos/FeatureSelectionConfig.java
+++ 
b/src/main/java/org/apache/sling/feature/maven/mojos/FeatureSelectionConfig.java
@@ -93,8 +93,12 @@ public class FeatureSelectionConfig {
     }
 
     public void setIncludeArtifact(final Dependency a) {
-        selections.add(new Selection(
-                SelectionType.ARTIFACT, 
ProjectHelper.toArtifactId(a).toMvnId()));
+        try {
+            selections.add(new Selection(
+                    SelectionType.ARTIFACT, 
ProjectHelper.toArtifactId(a).toMvnId()));
+        } catch (IllegalArgumentException ex) {
+            throw new IllegalArgumentException("Unable to set include 
artifact: " + a, ex);
+        }
     }
 
     public void setIncludeClassifier(final String classifier) {

Reply via email to