apache / apache/maven-shade-plugin
[MSHADE-380] Improve FAQ for multiple runs of plugin
- Dominant language
- Java
- Stars
- 188
- Forks
- 103
- Avg merge
- 16h 39m
- Merged PRs (30d)
- 4
Description
**[Gili](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=cowwoc)** opened **[MSHADE-380](https://issues.apache.org/jira/browse/MSHADE-380?redirect=false)** and commented
https://issues.apache.org/jira/browse/MSHADE-85 provides a vague recommendation to alter the output name to avoid a second run of the plugin from using the output of the first run as input. In practice this is a bad workaround because if you do this then maven-install-plugin ends up installing the non-shaded JAR file.
A much easier and cleaner solution is to set the \ property of the jar plugin as follows:
```java
org.apache.maven.plugins
maven-jar-plugin
default-jar
true
```
Please update the recommendations in the FAQ with the above suggestion. Please include the full code snippet to avoid any misunderstanding.
Bigger picture, the default behavior is bad. All maven plugins work properly by default across multiple runs. This plugin does not. What prevents you from leaving the output as foobar-shaded.jar and somehow hinting to the maven-install-plugin to use that as input instead? I don't know the exact implementation details, but certainly the happy path should work out of the box without users needing to jump through any hoops.
---
No further details from [MSHADE-380](https://issues.apache.org/jira/browse/MSHADE-380?redirect=false)
Contributor guide
No contributing guide indexed for this repository
Research direction
Locate the FAQ entry covering multiple runs of the Maven Shade Plugin and review its current recommendation. Update it with the complete maven-jar-plugin forceCreation example and explain the cleaner workaround; the FAQ should clearly address the installation behavior described in the issue.
Written by the indexing model from the issue text.
Assessment
- Domain
- build-system, documentation
- Issue type
- Documentation
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100