From cdf06e27da7010d5c9f8c031cffbee8b85929a37 Mon Sep 17 00:00:00 2001 From: antelder Date: Mon, 22 Mar 2010 11:55:34 +0000 Subject: Update to use the built artifact if the folder doesn't exist and to start a distributed doamin by default git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@926044 13f79535-47bb-0310-9956-ffa450edef68 --- .../main/java/org/apache/tuscany/maven/plugin/TuscanyRunMojo.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'maven-plugins/trunk/maven-tuscany-plugin') diff --git a/maven-plugins/trunk/maven-tuscany-plugin/src/main/java/org/apache/tuscany/maven/plugin/TuscanyRunMojo.java b/maven-plugins/trunk/maven-tuscany-plugin/src/main/java/org/apache/tuscany/maven/plugin/TuscanyRunMojo.java index 44f1067c14..1e35b1dbc1 100644 --- a/maven-plugins/trunk/maven-tuscany-plugin/src/main/java/org/apache/tuscany/maven/plugin/TuscanyRunMojo.java +++ b/maven-plugins/trunk/maven-tuscany-plugin/src/main/java/org/apache/tuscany/maven/plugin/TuscanyRunMojo.java @@ -74,7 +74,7 @@ public class TuscanyRunMojo extends AbstractMojo { protected File finalName; /** - * @parameter expression="${domain}" default-value="vm:default" + * @parameter expression="${domain}" default-value="tuscany:default" */ private String domain; @@ -105,7 +105,11 @@ public class TuscanyRunMojo extends AbstractMojo { protected void addProjectContribution(List cs) throws MojoExecutionException { try { - String contribution = new File(buildDirectory.getParent(), finalName.getName()).toURI().toURL().toString(); + File contributionFile = new File(buildDirectory.getParent(), finalName.getName()); + if (!contributionFile.exists()) { + contributionFile = new File(buildDirectory.getParent(), finalName.getName() + packaging); + } + String contribution = contributionFile.toURI().toURL().toString(); getLog().info("Project contribution: " + contribution); cs.add(contribution); -- cgit v1.2.3