Class CreateDMGMojo

java.lang.Object
org.apache.maven.plugin.AbstractMojo
org.eclipse.cbi.maven.plugins.dmgpackager.CreateDMGMojo
All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

@Mojo(name="package-dmg", defaultPhase=PACKAGE) public class CreateDMGMojo extends org.apache.maven.plugin.AbstractMojo
Create a DMG file from the file specified as argument. This plug-in requires access to the Eclipse DMG packager web service.
  • Field Details

    • volumeName

      @Parameter private String volumeName
      The user readable name of the DMG created. It is displayed in the Finder sidebar and window title.
      Since:
      1.1.3
    • volumeIcon

      @Parameter private File volumeIcon
      The icns file used for the DMG.
      Since:
      1.1.3
    • backgroundImage

      @Parameter private File backgroundImage
      A png file for background image for the installer.
      Since:
      1.1.3
    • windowSize

      @Parameter(defaultValue="480 300") private String windowSize
      The size of the installer window. Coordinates are expressed as X Y (e.g. 480 300)
      Since:
      1.1.3
    • windowPosition

      @Parameter(defaultValue="50 50") private String windowPosition
      The position of the installer window when it opens. Coordinates are expressed as X Y (e.g. 50 50).
      Since:
      1.1.3
    • iconSize

      @Parameter(defaultValue="125") private String iconSize
      The size of the icon to display in the installer.
      Since:
      1.1.3
    • icon

      @Parameter private String icon
      Name of the icon to display and position, e.g., "Eclipse.app x y". Recommended size 100 125
      Since:
      1.1.3
    • dropLinkPosition

      @Parameter(defaultValue="375 125") private String dropLinkPosition
      Location of the drop link to Applications folder.
      Since:
      1.1.3
    • eulaFile

      @Parameter private File eulaFile
      File to attach as a license.
      Since:
      1.1.3
    • source

      @Parameter(required=true) private File source
      An .tar.gz or .zip file containing a single OS X application to create the DMG for.
      Since:
      1.1.3
    • serviceUrl

      @Parameter(required=true, property="cbi.dmgpackager.serviceUrl", defaultValue="http://build.eclipse.org:31338/dmg-packager") private String serviceUrl
      The URL for creating DMG files

      The signing service return a dmg file of the application passed as a source.

      Since:
      1.1.3
    • target

      @Parameter private File target
      Where the new DMG file should be saved. If it is not specified, the file is placed beside source.
      Since:
      1.1.3
    • skip

      @Parameter(property="cbi.dmgpackager.skip", defaultValue="false") private boolean skip
      Skips the execution of this plugin
      Since:
      1.1.3
    • continueOnFail

      @Parameter(property="cbi.dmgpackager.continueOnFail", defaultValue="false") private boolean continueOnFail
      Whether the build should be stopped if the packaging process fails.
      Since:
      1.1.3
    • sign

      @Parameter(property="cbi.dmgpackager.sign", defaultValue="false") private boolean sign
      Controls signing of the dmg file
      Since:
      1.1.4
    • timeoutMillis

      @Parameter(property="cbi.dmgpackager.timeoutMillis", defaultValue="0") private int timeoutMillis
      Determines the timeout in milliseconds for any communication with the packaging/signing server. A timeout value of zero is interpreted as an infinite timeout.
      Since:
      1.1.5
  • Constructor Details

    • CreateDMGMojo

      public CreateDMGMojo()
  • Method Details

    • execute

      public void execute() throws org.apache.maven.plugin.MojoExecutionException
      Throws:
      org.apache.maven.plugin.MojoExecutionException
    • callDMGService

      private void callDMGService(ExceptionHandler exceptionHandler) throws IOException, org.apache.maven.plugin.MojoExecutionException
      Throws:
      IOException
      org.apache.maven.plugin.MojoExecutionException
    • processOnRemoteServer

      private void processOnRemoteServer(HttpClient httpClient, HttpRequest request) throws IOException
      Throws:
      IOException