apache / apache/maven-shade-plugin

[MSHADE-333] Shading of sources uses hard-coded classifier "sources"

Open
#335 0 comments 0 reactions 0 assignees View on GitHub
bug priority:minor
Dominant language
Java
Stars
188
Forks
103
Avg merge
16h 39m
Merged PRs (30d)
4

Description

**[Peter De Maeyer](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=peterdm)** opened **[MSHADE-333](https://issues.apache.org/jira/browse/MSHADE-333?redirect=false)** and commented

Shading sources only works for the default classifier "sources".
The [maven-source-plugin](https://maven.apache.org/plugins/maven-source-plugin/jar-mojo.html) can be configured to use a different classifier with the optional parameter ``, but then shading no longer works.
Ideally, shading of sources should adopt/recognize the classifier(s) of the project(s).

The root cause is that the classifier "sources" is hard-coded in `ShadeMojo`.

---

**Affects:** 3.2.1

**Issue Links:**
- [MSHADE-285](https://issues.apache.org/jira/browse/MSHADE-285) It should be possible to shade test sources as a JAR

Contributor guide

No contributing guide indexed for this repository

Research direction

Start in ShadeMojo, where the issue identifies the hard-coded "sources" classifier, and review the linked MSHADE-285 issue for related behavior. Trace how source artifacts receive their classifier and verify that shading recognizes classifiers configured by the project or its dependencies; done means non-default source classifiers are shaded correctly.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
build-system
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.