The Setup Builder is a plugin for Gradle which can create a native setups for different platforms like Windows, Linux and OSX. The output is a *.msi, a *.deb, a *.rpm or a *.dmg file. The target is an installer for Java applications.
| Platform | Requirement |
|---|---|
| all | Java 8 or higher. Gradle must run with Java 8 |
| Windows | Wix Toolset or WixEdit must be installed |
| Linux | Lintian, FakeRoot on Ubuntu: apt-get install lintian fakeroot |
| Linux | dpkg for creating Debian packages: apt-get install dpkg |
| Linux | rpm for creating RPM packages: apt-get install rpm |
| Plugin Version | Gradle Version |
|---|---|
| <= 1.5 | 2.3 - 2.11 |
| 1.6 | 2.12 - 2.13 |
| 1.7 | 2.14 |
| 1.8 | 3.0 |
The plugin add the follow tasks:
- msi
- deb
- rpm
- dmg
plugins {
id "de.inetsoftware.setupbuilder" version "1.8"
}
setupBuilder {
vendor = 'i-net software'
application = "SetupBuilder Plugin"
appIdentifier = "SetupBuilder"
version = '1.0'
licenseFile = 'license.txt'
// icons in different sizes for different usage. you can also use a single *.ico or *.icns file
icons = ['icon16.png', 'icon32.png', 'icon48.png', 'icon128.png']
// all files for all platforms
from( 'source' ) {
include 'files/*.jar'
}
bundleJre = 1.8
}
msi {
// files only for the Windows platform
from( 'windows' ) {
include 'foo.exe'
rename { 'bar.exe' }
}
}
More properties can be found in the sources of setupBuilder, msi, deb, rpm and dmg.
Create a zip file with the same files define in setupBuilder extension.
...
setupBuilder {
...
}
task zip(type: Zip) {
with setupBuilder
doLast {
artifacts {
archives zip
}
}
}
Apache License, Version 2.0