source: jomc/branches/jomc-1.x/maven-jomc-plugin/BUILDING.txt@ 4613

Last change on this file since 4613 was 4613, checked in by Christian Schulte, 13 years ago

o Merged changes up to 4612 from 'trunk' into branch 'jomc-1.x'.

See #1.

  • Property svn:eol-style set to native
  • Property svn:keywords set to JOMC=%b%_%r%_%d%_%a
  • Property svn:mime-type set to text/plain
File size: 11.3 KB
Line 
1 $JOMC: BUILDING.txt 4613 2012-09-22 10:07:08Z schulte $
2
3 Build Requirements
4 ------------------
5
6 In order to build JOMC artifacts, the following software needs to be
7 installed.
8
9 o Java Development Kit (JDK), Version 1.6 or higher
10
11 Please consult the operating system documentation on how to install a Java
12 development kit.
13
14 o Apache Maven 3.x
15
16 The following link redirects to the official Apache Maven website.
17 http://www.jomc.org/redirect/mng
18
19 In order to build JOMC release artifacts, the following software needs to be
20 installed in addition.
21
22 o GnuPG
23
24 The following link redirects to the official GnuPG website.
25 http://www.jomc.org/redirect/gpg
26
27
28 Building Snapshot Artifacts
29 ---------------------------
30
31 For building snapshot artifacts, no further setup is required.
32
33 Artifact sources are compiled by executing:
34 cmd> mvn compile
35
36 Unit tests are run by executing:
37 cmd> mvn test
38
39 Snapshot archives are created by executing:
40 cmd> mvn package
41
42 Snapshot artifacts are installed by executing:
43 cmd> mvn install
44
45 The project site is build by executing:
46 cmd> mvn site
47
48 Building Release Artifacts
49 --------------------------
50
51 For building release artifacts, various properties need to be set. This is
52 done by using the '-D' command line option. To minimize the number of '-D'
53 options, a profile can be added to the local Maven settings.xml file. The
54 following link redirects to the official Maven settings reference.
55 http://www.jomc.org/redirect/msettings
56
57 <profile>
58 <id>jomc.org</id>
59 <properties>
60 <!-- -->
61 <!-- -->
62 <!-- Source Code Management System Properties -->
63 <!-- ======================================== -->
64 <!-- -->
65 <!-- The 'jomc.scm.username' property must be set to the name of the -->
66 <!-- user used for authentication with the project source code -->
67 <!-- management system. -->
68 <!-- -->
69 <jomc.scm.username>Username</jomc.scm.username>
70 <!-- -->
71 <!-- The 'jomc.scm.password' property must be set to the password -->
72 <!-- used for authentication with the project source code management -->
73 <!-- system. To avoid storing cleartext passwords, this property -->
74 <!-- should be set using the '-D' command line option. -->
75 <!-- -->
76 <jomc.scm.password>Password</jomc.scm.password>
77 <!-- -->
78 <!-- -->
79 <!-- Code Signing Properties -->
80 <!-- ======================= -->
81 <!-- -->
82 <!-- Code signing is backed by the 'maven-jarsigner-plugin'. -->
83 <!-- The following link redirects to the official documentation of -->
84 <!-- that plugin. http://www.jomc.org/redirect/mjarsigner -->
85 <!-- -->
86 <!-- -->
87 <!-- The 'jarsigner.keystore' property may be set to the location of -->
88 <!-- the keystore used for signing Java archives. -->
89 <!-- -->
90 <!-- <jarsigner.keystore>Location</jarsigner.keystore> -->
91 <!-- -->
92 <!-- The 'jarsigner.storepass' property may be set to the password -->
93 <!-- of the keystore used for signing Java archives. To avoid -->
94 <!-- storing cleartext passwords, this property should be set using -->
95 <!-- the '-D' command line option. -->
96 <!-- -->
97 <!-- <jarsigner.storepass>Password</jarsigner.storepass> -->
98 <!-- -->
99 <!-- The 'jarsigner.alias' property must be set to the alias of the -->
100 <!-- certificate used for signing Java archives. -->
101 <!-- -->
102 <jarsigner.alias>Alias</jarsigner.alias>
103 <!-- -->
104 <!-- The 'jarsigner.keypass' property may be set to the password of -->
105 <!-- the certificate used for signing Java archives. To avoid -->
106 <!-- storing cleartext passwords, this property should be set using -->
107 <!-- the '-D' command line option. -->
108 <!-- -->
109 <!-- <jarsigner.keypass>Password</jarsigner.keypass> -->
110 <!-- -->
111 <!-- The 'jarsigner.tsa' property must be set to an URL of a -->
112 <!-- timestamping authority used for signing Java archives. -->
113 <!-- -->
114 <!-- For example: -->
115 <!-- https://timestamp.geotrust.com/tsa -->
116 <!-- -->
117 <jarsigner.tsa>URL</jarsigner.tsa>
118 <!-- -->
119 <!-- -->
120 <!-- Artifact Signing Properties -->
121 <!-- =========================== -->
122 <!-- -->
123 <!-- Artifact signing is backed by the 'maven-gpg-plugin'. -->
124 <!-- The following link redirects to the official documentation of -->
125 <!-- that plugin. http://www.jomc.org/redirect/mgpg -->
126 <!-- -->
127 <!-- -->
128 <!-- The 'gpg.keyname' property may be set to the name of the GPG -->
129 <!-- key used for signing artifacts. -->
130 <!-- -->
131 <!-- <gpg.keyname>Key</gpg.keyname> -->
132 <!-- -->
133 <!-- The 'gpg.passphrase' property may be set to the passphrase of -->
134 <!-- the GPG key used for signing artifacts. To avoid storing -->
135 <!-- cleartext passwords, this property should be set using the '-D' -->
136 <!-- command line option. -->
137 <!-- -->
138 <!-- <gpg.passphrase>Passphrase</gpg.passphrase> -->
139 <!-- -->
140 <!-- -->
141 </properties>
142 </profile>
143
144 That profile is enabled by using the '-P' command line option.
145
146 Release archives are created by executing:
147 cmd> mvn -Pjomc-release,jomc.org verify
148
149 Release artifacts are installed by executing:
150 cmd> mvn -Pjomc-release,jomc.org install
151
152
153 Deploying Snapshot Artifacts
154 ----------------------------
155
156 Snapshot artifacts are deployed by executing:
157 cmd> mvn deploy
158
159 For this to work, a server definition needs to be specified in the local
160 Maven settings.xml file used for authentication with the remote snapshot
161 repository.
162
163 <server>
164 <id>sonatype-nexus-snapshots</id>
165 <username>OSS Username</username>
166 <password>OSS Password</password>
167 </server>
168
169 Optionally, to use deployed snapshot artifacts, a corresponding profile
170 may be added to the local Maven settings.xml file.
171
172 <profile>
173 <id>oss.sonatype.org</id>
174 <repositories>
175 <repository>
176 <id>sonatype-nexus-snapshots</id>
177 <name>Sonatype Nexus Snapshots</name>
178 <url>https://oss.sonatype.org/content/repositories/snapshots</url>
179 <releases>
180 <enabled>false</enabled>
181 </releases>
182 <snapshots>
183 <enabled>true</enabled>
184 </snapshots>
185 </repository>
186 </repositories>
187 <pluginRepositories>
188 <pluginRepository>
189 <id>sonatype-nexus-snapshots</id>
190 <name>Sonatype Nexus Snapshots</name>
191 <url>https://oss.sonatype.org/content/repositories/snapshots</url>
192 <releases>
193 <enabled>false</enabled>
194 </releases>
195 <snapshots>
196 <enabled>true</enabled>
197 </snapshots>
198 </pluginRepository>
199 </pluginRepositories>
200 </profile>
201
202 That profile is enabled by using the '-P' command line option.
203 For example:
204
205 cmd> mvn -Poss.sonatype.org compile
206 cmd> mvn -Poss.sonatype.org test
207 cmd> mvn -Poss.sonatype.org package
208 cmd> mvn -Poss.sonatype.org install
209 cmd> mvn -Poss.sonatype.org site
210
211 The following link redirects to the repository hosting service used by this
212 project. http://www.jomc.org/redirect/oss
213
214 Deploying Release Artifacts
215 ---------------------------
216
217 For deploying release artifacts, a server definition needs to be specified
218 in the local Maven settings.xml file used for authentication with the remote
219 staging repository.
220
221 <server>
222 <id>sonatype-nexus-staging</id>
223 <username>OSS Username</username>
224 <password>OSS Password</password>
225 </server>
226
227 Release artifacts are deployed by executing:
228 cmd> mvn -Pjomc-release,jomc.org deploy
229
230 Project Site Deployment
231 -----------------------
232
233 For deploying the project web site, a server definition needs to be
234 specified in the local Maven settings.xml file used for authentication with
235 the project web server.
236
237 <server>
238 <id>jomc.org</id>
239 <username>Username</username>
240 <password>Password</password>
241 </server>
242
243 The project web site is deployed by executing:
244 cmd> mvn site-deploy
245
246 Releasing Artifacts
247 -------------------
248
249 The release process is backed by the 'maven-release-plugin'. The following
250 link redirects to the official documentation of that plugin.
251 http://www.jomc.org/redirect/mrelease
252
253 Releases are prepared by executing:
254 cmd> mvn release:prepare -Pjomc-release,jomc.org
255
256 Releases are performed by executing:
257 cmd> mvn release:perform -Darguments="-Pjomc-release,jomc.org"
258
Note: See TracBrowser for help on using the repository browser.