@Override protected void executeTask() throws BuildException { if (this.property == null) throw new BuildException("Target property (attribute 'property') not specified."); log("Attempting to resolve output URL '" + project().getOutputUrl() + "'", Project.MSG_VERBOSE); final String outputDirectory; try { outputDirectory = UriUtils.getPath(projectResolver().resolveUriString(project().getOutputUrl())); } catch (ResolutionException e) { throw new BuildException("Failed to resolve project output directory.", e); } log("Output URL resolved to '" + outputDirectory + "'", Project.MSG_VERBOSE); getProject().setProperty(this.property, outputDirectory); }