-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathInstallerGriffonPlugin.groovy
110 lines (94 loc) · 4.19 KB
/
InstallerGriffonPlugin.groovy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
/*
* Copyright 2009-2012 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/**
* @author Andres Almiray
* @author Josh Reed
*/
class InstallerGriffonPlugin {
// the plugin version
String version = '0.8'
// the version or versions of Griffon the plugin is designed for
String griffonVersion = '1.0.0 > *'
// the other plugins this plugin depends on
Map dependsOn = [:]
// resources that are included in plugin packaging
List pluginIncludes = []
// the plugin license
String license = 'Apache Software License 2.0'
// Toolkit compatibility. No value means compatible with all
// Valid values are: swing, javafx, swt, pivot, gtk
List toolkits = []
// Platform compatibility. No value means compatible with all
// Valid values are:
// linux, linux64, windows, windows64, macosx, macosx64, solaris
List platforms = []
// URL where documentation can be found
String documentation = ''
// URL where source can be found
String source = 'https://github.com/griffon/griffon-installer-plugin'
// Install as a framework plugin
boolean framework = true
List authors = [
[
name: 'Andres Almiray',
email: '[email protected]'
],
[
name: 'Josh Reed',
email: '[email protected]'
]
]
String title = 'Creates launchers and installers for your Griffon application'
// accepts Markdown syntax. See http://daringfireball.net/projects/markdown/ for details
String description = '''
The Installer plugin provides useful packaging and installation solutions for your Griffon application.
The plugin creates two types of artifacts, launchers and installers. Launchers package your application
in platform-specific ways, such as an .exe file for Windows and a .app bundle for Mac.
Installers install your packaged app onto the user's computer. The current supported options are:
**Launchers**
* Windows (JSmooth) - creates a .exe for launching your application on Windows
* Mac - creates a Mac application bundle (.app) for launching your application on Mac OS X
**Installers**
* IzPack - platform independent installer, highly configurable.
* RPM - RedHat Package Manager based installer, works on RedHat, Fedora, CentOS, Mandriva.
* DEB - Debian based package installer, works on Debian, Ubuntu.
* DMG - MacOSX disk image
Usage
-----
Creating a launcher or installer is a two step process. First you prepare the configuration files for that
launcher/installer by running the prepare-XXX script. This will copy the standard configuration files into
the installer/XXX directory so you can tweak them as needed. This step only needs to be performed once for
the application. The second step is to actually create the launcher/installer by running the create-XXX script.
This will create the actual launcher or installer in the installer/XXX/dist directory. This step should be
performed every time you want to release a new version of your application.
The provided scripts are:
* **prepare-deb** / **create-deb**
* **prepare-rpm** / **create-rpm**
* **prepare-izpack** / **create-izpack**
* **prepare-mac** / **create-mac**
* **prepare-jsmooth** / **create-jsmooth**
* **prepare-windows** / **create-windows **// delegates to jsmooth
All these targets can be called using the standard package command too, for example
griffon package izpack
produces the same result as
griffon prepare-izpack
griffon create-izpack
Notes
-----
Preparing and creating the launchers is cross-platform, e.g. you can 'create-windows' even if you are developing
on a Linux or Mac machine (and vice-versa). Building an DMG requires running MacOSX.
'''
}