throw new IOException( "ArchiverException: " + e.getMessage() );
@Override public void execute() throws MojoExecutionException, MojoFailureException { try { packageAndAttachAppStoreMetaData(); } catch (IOException e) { throw new MojoExecutionException(e.getMessage(), e); } catch (NoSuchArchiverException e) { throw new MojoExecutionException(e.getMessage(), e); } catch (ArchiverException e) { throw new MojoExecutionException(e.getMessage(), e); } }
/** * Executes the JarMojo on the current project. * * @throws MojoExecutionException if an error occurred while building the webapp */ public void execute() throws MojoExecutionException { try { performPackaging(); } catch (DependencyResolutionRequiredException e) { throw new MojoExecutionException("Error assembling jar: " + e.getMessage(), e); } catch (ManifestException e) { throw new MojoExecutionException("Error assembling jar", e); } catch (IOException e) { throw new MojoExecutionException("Error assembling jar", e); } catch (ArchiverException e) { throw new MojoExecutionException("Error assembling jar: " + e.getMessage(), e); } }
/** * Executes the WarMojo on the current project. * * @throws MojoExecutionException if an error occurred while building the webapp */ public void execute() throws MojoExecutionException { try { performPackaging(); } catch (DependencyResolutionRequiredException e) { throw new MojoExecutionException("Error assembling hpi: " + e.getMessage(), e); } catch (ManifestException e) { throw new MojoExecutionException("Error assembling hpi", e); } catch (IOException e) { throw new MojoExecutionException("Error assembling hpi", e); } catch (ArchiverException e) { throw new MojoExecutionException("Error assembling hpi: " + e.getMessage(), e); } }
@Override public void execute() throws MojoExecutionException, MojoFailureException { for (final String sdk : getSDKs()) { for (final String config : getConfigurations()) { try { packageAndAttachDSym(sdk, config); } catch (IOException e) { throw new MojoExecutionException(e.getMessage(), e); } catch (NoSuchArchiverException e) { throw new MojoExecutionException(e.getMessage(), e); } catch (ArchiverException e) { throw new MojoExecutionException(e.getMessage(), e); } catch (XCodeException e) { throw new MojoExecutionException(e.getMessage(), e); } } } }
throw new IOException( "ArchiverException: " + e.getMessage() );
throw new MojoExecutionException( "Error assembling WAR: " + e.getMessage(), e );
public File getJarFile() throws IOException { if ( tempJarFile == null ) { try { tempJarFile = File.createTempFile( "mvn-eclipse", null ); tempJarFile.deleteOnExit(); JarArchiver jarArchiver = new JarArchiver(); jarArchiver.setDestFile( tempJarFile ); jarArchiver.addDirectory( getFile() ); jarArchiver.setManifest( getManifestFile() ); jarArchiver.createArchive(); return tempJarFile; } catch ( ArchiverException e ) { // TODO only accepts the cause as parameter in JDK 1.6+ throw new IOException( e.getMessage() ); } } return tempJarFile; }
throw new MojoExecutionException(e.getMessage(),e); } catch (ArchiverException e) { throw new MojoExecutionException(e.getMessage(),e);
} catch (ArchiverException e) { throw new MavenExecutionException("Failed to unpack Tycho's OSGi runtime: " + e.getMessage(), e);
private final void archive(final String archiverType, final File rootDir, final File archive, final String[] includes, final String[] excludes) throws NoSuchArchiverException, IOException, XCodeException { try { final Archiver archiver = archiverManager.getArchiver(archiverType); archiver.addDirectory(rootDir, includes, excludes); archiver.setDestFile(archive); archiver.createArchive(); } catch (ArchiverException ex) { throw new XCodeException("Could not archive folder '" + rootDir + "' into '" + archive + "': " + ex.getMessage(), ex); } }
throw new MojoExecutionException("Error creating obr archive: " + e.getMessage(), e);
throw new MojoExecutionException( "Error creating source archive: " + e.getMessage(), e );
throw new MojoExecutionException("Error creating obr archive: " + e.getMessage(), e);
throw new MojoExecutionException("Error creating obr archive: " + e.getMessage(), e);
throw new ArchiveCreationException( "Error adding file to archive: " + e.getMessage(), e );
throw new MavenExecutionException( "Failed to unpack P2 runtime: " + e.getMessage(), e );
private void asFile( Archiver archiver, AssemblerConfigurationSource configSource, String destDirectory ) throws AssemblyFormattingException, ArchiveCreationException { final String tempMapping = AssemblyFormatUtils.evaluateFileNameMapping( outputFileNameMapping, artifact, configSource.getProject(), moduleArtifact, configSource, AssemblyFormatUtils.moduleProjectInterpolator( moduleProject ), AssemblyFormatUtils.artifactProjectInterpolator( project ) ); final String outputLocation = destDirectory + tempMapping; try { final File artifactFile = artifact.getFile(); logger.debug( "Adding artifact: " + artifact.getId() + " with file: " + artifactFile + " to assembly location: " + outputLocation + "." ); if ( fileMode != -1 ) { archiver.addFile( artifactFile, outputLocation, fileMode ); } else { archiver.addFile( artifactFile, outputLocation ); } } catch ( final ArchiverException e ) { throw new ArchiveCreationException( "Error adding file '" + artifact.getId() + "' to archive: " + e.getMessage(), e ); } }
"Error adding file-set for '" + artifact.getId() + "' to archive: " + e.getMessage(), e );