Package org.codehaus.plexus.archiver.tar

Examples of org.codehaus.plexus.archiver.tar.TarArchiver.createArchive()


        try
        {
            tarCompressionMethod.setValue( "gzip" );
            tarArchiver.setCompression( tarCompressionMethod );
            tarArchiver.setIncludeEmptyDirs( false );
            tarArchiver.createArchive();
        }
        catch ( ArchiverException e )
        {
            throw new MojoExecutionException( "NPANDAY-1700-002", e );
        }
View Full Code Here


    protected void createDockerArchive(File archive, File dockerDir) throws IOException {
        TarArchiver archiver = new TarArchiver();
        archiver.addDirectory(dockerDir);
        archiver.setDestFile(archive);
        archiver.createArchive();
    }

    protected String ensureEndsWithFileSeparator(String path) {
        if (path == null) {
            path = ".";
View Full Code Here

                    else if (entry.getSource().isDirectory()) {
                        tar.addDirectory(entry.getSource(),
                                         entry.getPathInGem());
                    }
                }
                tar.createArchive();
            }

            // and finally create gem by tar.gz-ing data.tar.gz and metadata.gz
            final File gemFile = new File(target, gem.getGemFilename());
            tar.setDestFile(gemFile);
View Full Code Here

            tar.setCompression(compression);
            if (dataTarGz != null) {
                tar.addFile(dataTarGz, dataTarGz.getName());
            }
            tar.addFile(metadataGz, metadataGz.getName());
            tar.createArchive();

            return gemFile;
        }
        catch (final ArchiverException e) {
            final IOException ioe = new IOException(e.getMessage());
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.