Merge branch '2.0.x'
This commit is contained in:
@@ -456,8 +456,8 @@ public abstract class AbstractRunMojo extends AbstractDependencyFilterMojo {
|
||||
|
||||
private void addDependencies(List<URL> urls)
|
||||
throws MalformedURLException, MojoExecutionException {
|
||||
FilterArtifacts filters = this.useTestClasspath ? getFilters()
|
||||
: getFilters(new TestArtifactFilter());
|
||||
FilterArtifacts filters = (this.useTestClasspath ? getFilters()
|
||||
: getFilters(new TestArtifactFilter()));
|
||||
Set<Artifact> artifacts = filterDependencies(this.project.getArtifacts(),
|
||||
filters);
|
||||
for (Artifact artifact : artifacts) {
|
||||
@@ -505,7 +505,7 @@ public abstract class AbstractRunMojo extends AbstractDependencyFilterMojo {
|
||||
public void uncaughtException(Thread thread, Throwable ex) {
|
||||
if (!(ex instanceof ThreadDeath)) {
|
||||
synchronized (this.monitor) {
|
||||
this.exception = (this.exception == null ? ex : this.exception);
|
||||
this.exception = (this.exception != null ? this.exception : ex);
|
||||
}
|
||||
getLog().warn(ex);
|
||||
}
|
||||
|
||||
@@ -144,8 +144,8 @@ public class RepackageMojo extends AbstractDependencyFilterMojo {
|
||||
|
||||
/**
|
||||
* A list of the libraries that must be unpacked from fat jars in order to run.
|
||||
* Specify each library as a {@code <dependency>} with a {@code <groupId>} and
|
||||
* a {@code <artifactId>} and they will be unpacked at runtime.
|
||||
* Specify each library as a {@code <dependency>} with a {@code <groupId>} and a
|
||||
* {@code <artifactId>} and they will be unpacked at runtime.
|
||||
* @since 1.1
|
||||
*/
|
||||
@Parameter
|
||||
@@ -156,10 +156,10 @@ public class RepackageMojo extends AbstractDependencyFilterMojo {
|
||||
* jar.
|
||||
* <p>
|
||||
* Currently, some tools do not accept this format so you may not always be able to
|
||||
* use this technique. For example, {@code jar -xf} may silently fail to extract
|
||||
* a jar or war that has been made fully-executable. It is recommended that you only
|
||||
* enable this option if you intend to execute it directly, rather than running it
|
||||
* with {@code java -jar} or deploying it to a servlet container.
|
||||
* use this technique. For example, {@code jar -xf} may silently fail to extract a jar
|
||||
* or war that has been made fully-executable. It is recommended that you only enable
|
||||
* this option if you intend to execute it directly, rather than running it with
|
||||
* {@code java -jar} or deploying it to a servlet container.
|
||||
* @since 1.3
|
||||
*/
|
||||
@Parameter(defaultValue = "false")
|
||||
@@ -226,7 +226,7 @@ public class RepackageMojo extends AbstractDependencyFilterMojo {
|
||||
}
|
||||
|
||||
private File getTargetFile() {
|
||||
String classifier = (this.classifier == null ? "" : this.classifier.trim());
|
||||
String classifier = (this.classifier != null ? this.classifier.trim() : "");
|
||||
if (!classifier.isEmpty() && !classifier.startsWith("-")) {
|
||||
classifier = "-" + classifier;
|
||||
}
|
||||
@@ -287,7 +287,7 @@ public class RepackageMojo extends AbstractDependencyFilterMojo {
|
||||
}
|
||||
|
||||
private String removeLineBreaks(String description) {
|
||||
return (description == null ? null : description.replaceAll("\\s+", " "));
|
||||
return (description != null ? description.replaceAll("\\s+", " ") : null);
|
||||
}
|
||||
|
||||
private void putIfMissing(Properties properties, String key,
|
||||
|
||||
Reference in New Issue
Block a user