Skip to content

Maven plugin that creates an Application Bundle for OS X containing all your project dependencies and the necessary metadata.

License

Notifications You must be signed in to change notification settings

mobreza/appbundle-maven-plugin

This branch is 42 commits behind federkasten/appbundle-maven-plugin:master.

Folders and files

NameName
Last commit message
Last commit date

Latest commit

author
Takashi AOKI
Jul 23, 2015
315e852 · Jul 23, 2015

History

59 Commits
Jul 23, 2015
Jul 23, 2015
Mar 3, 2015
Oct 27, 2014
Jul 23, 2015
Feb 15, 2015
Jul 23, 2015

Repository files navigation

appbundle-maven-plugin

Maven plugin that creates an Application Bundle for OS X containing all your project dependencies and the necessary metadata.

<plugin>
  <groupId>sh.tak.appbundler</groupId>
  <artifactId>appbundle-maven-plugin</artifactId>
  <version>1.0.4</version>
  <configuration>
    <mainClass>your.app.MainClass</mainClass>
  </configuration>
  <executions>
    <execution>
      <phase>package</phase>
      <goals>
        <goal>bundle</goal>
      </goals>
    </execution>
  </executions>
</plugin>

Package with following command,

mvn package appbundle:bundle

Use Custom Info.plist and Icon

Put your custom Info.plist and Icon.icns under your maven resource paths (src/main/resources on default configuration).

Configure pom.xml like below,

<configuration>
   <mainClass>your.app.MainClass</mainClass>
   <dictionaryFile>YourCustomInfo.plist</dictionaryFile>
   <iconFile>CustomIncon.icns</iconFile>
</configuration>

Embedd Java Runtime Environment

Locate the JRE or JDK on your Mac (/Library/Java/JavaVirtualMachines/ on default configuration).

Configure pom.xml like below,

<configuration>
   <mainClass>your.app.MainClass</mainClass>
   <jrePath>/Library/Java/JavaVirtualMachines/jdk1.7.0_75.jdk</jrePath>
</configuration>

How to create DMG

You can create DMG(Apple disk image) file with the following command,

hdiutil create -srcfolder path/to/archive path/to/YourApplication.dmg

About this plugin

As you may know, Apple has dropped Java development from OS X excluding security patches.

mojo's osxappbundle-maven-plugin depends on Apple's Java launcher, so it does not support Java version 7 and future.

Oracle's Java Application Bundler supports other Java runtime (including Java 7, 8 and more), but it does not support maven.

I merged both and fix to work as a maven plugin that supports latest Mac OS X.

License

Copyright 2014 - 2015, Takashi AOKI and other contributors.

Copyright 2012, Oracle and/or its affiliates.

native/main.m is licensed under the GNU General Public License version 2.

Other files are licensed under the Apache License, Version 2.0.

About

Maven plugin that creates an Application Bundle for OS X containing all your project dependencies and the necessary metadata.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 78.7%
  • Objective-C 19.9%
  • Shell 1.4%