diff options
author | Mark Donszelmann <Mark.Donszelmann@gmail.com> | 2009-12-23 22:01:58 +0100 |
---|---|---|
committer | Mark Donszelmann <Mark.Donszelmann@gmail.com> | 2009-12-23 22:01:58 +0100 |
commit | 6a702cb7dfada3e86029f5d378a439246aedb757 (patch) | |
tree | 48f04f8ff3579f16d4d5e6c07f32dcb887bc12c4 | |
parent | b9a34889f9219d3f36d8af8a9f74af8872a7befb (diff) | |
download | maven-nar-plugin-6a702cb7dfada3e86029f5d378a439246aedb757.tar.gz maven-nar-plugin-6a702cb7dfada3e86029f5d378a439246aedb757.tar.bz2 maven-nar-plugin-6a702cb7dfada3e86029f5d378a439246aedb757.tar.xz maven-nar-plugin-6a702cb7dfada3e86029f5d378a439246aedb757.zip |
Skip running executable if it does not exist
-rw-r--r-- | src/main/java/org/apache/maven/plugin/nar/NarTestMojo.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/main/java/org/apache/maven/plugin/nar/NarTestMojo.java b/src/main/java/org/apache/maven/plugin/nar/NarTestMojo.java index ce5c8f0..549be88 100644 --- a/src/main/java/org/apache/maven/plugin/nar/NarTestMojo.java +++ b/src/main/java/org/apache/maven/plugin/nar/NarTestMojo.java @@ -105,6 +105,10 @@ public class NarTestMojo new File( getLayout().getBinDirectory( getTargetDirectory(), getMavenProject().getArtifactId(), getMavenProject().getVersion(), getAOL().toString() ), project.getArtifactId() ); + if (!executable.exists()) { + getLog().warn( "Skipping executable "+executable ); + return; + } getLog().info( "Running executable " + executable ); List args = library.getArgs(); int result = |