Changes for page Quick Start

Last modified by Paul Hoadley on 2025/01/30 02:09

From version 33.1
edited by Lachlan Deck
on 2008/11/23 15:37
Change comment: Adding tip for installing on mac
To version 39.1
edited by johnc
on 2009/04/26 18:23
Change comment: Changed -DarchetypeVersion=2.0.16 to 2.0.17

Summary

Details

Page properties
Author
... ... @@ -1,1 +1,1 @@
1 -XWiki.ldeck
1 +XWiki.johnc
Content
... ... @@ -1,3 +1,7 @@
1 +== Outline ==
2 +
3 +{{toc style="disc" indent="20px"}}{{/toc}}
4 +
1 1  == Step 1: Installing Maven ==
2 2  
3 3  Downloading and installing the latest version of [[Maven>>http://maven.apache.org/download]] is the first step to start using this tool.
... ... @@ -12,22 +12,24 @@
12 12  
13 13  {{/tip}}
14 14  
15 -**NOTE**: It is very helpful if you understand some Maven concepts before continue with this tutorial. See [[General Maven Documentation]] for more information.
19 +**NOTE**: It is very helpful if you understand some Maven concepts before continuing with this tutorial. See [[General Maven Documentation]] for more information.
16 16  
17 17  == Step 2: Configuring your Maven Settings ==
18 18  
19 -Before start using Maven, you have to configure it in order to use the plug-ins provided by WOProject. General Maven configuration is made in a settings.xml file. This file can be found at .m2 folder in the user home (,,/.m2 on Unix systems and C:ocuments and Settingsserm2 on Windows). If this file doesn't exist yet, just create it.,,
23 +Before start using Maven, you have to configure it in order to use the plug-ins provided by WOProject. General Maven configuration is made in a settings.xml file. This file can be found in a folder called ##.m2## in each user's home directory (,,/.m2 on Unix systems and C:ocuments and SettingsserNamem2 on Windows). If this file does not yet exist, you can just create it.,,
20 20  
21 -You have to define the WOProject plug-in group and the repositories to download the plug-ins. The following snippet shows how to make this configuration:
25 +You have to define the WOProject plug-in group and the repositories to download the plug-ins. The following xml is sufficient to configure maven for using WOProject-maven plugin:
22 22  
23 23  {{noformat}}
24 24  
25 -<settings>
26 - ...
29 +<settings xmlns="http://maven.apache.org/POM/4.0.0"
30 + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
31 + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
32 + http://maven.apache.org/xsd/settings-1.0.0.xsd">
27 27   <pluginGroups>
28 28   <pluginGroup>org.objectstyle.woproject.maven2</pluginGroup>
29 29   </pluginGroups>
30 - ...
36 +
31 31   <profiles>
32 32   <profile>
33 33   <id>default</id>
... ... @@ -34,12 +34,40 @@
34 34   <activation>
35 35   <activeByDefault>true</activeByDefault>
36 36   </activation>
43 + <repositories>
44 + <repository>
45 + <id>wocommunity.releases</id>
46 + <name>WOCommunity Releases Repository</name>
47 + <url>
48 + http://maven.wocommunity.org/content/groups/public
49 + </url>
50 + <releases>
51 + <enabled>true</enabled>
52 + </releases>
53 + <snapshots>
54 + <enabled>false</enabled>
55 + </snapshots>
56 + </repository>
57 + <repository>
58 + <id>wocommunity.snapshots</id>
59 + <name>WOCommunity Snapshots Repository</name>
60 + <url>
61 + http://maven.wocommunity.org/content/groups/public-snapshots
62 + </url>
63 + <releases>
64 + <enabled>false</enabled>
65 + </releases>
66 + <snapshots>
67 + <enabled>true</enabled>
68 + </snapshots>
69 + </repository>
70 + </repositories>
37 37   <pluginRepositories>
38 38   <pluginRepository>
39 - <id>mdimension.releases</id>
40 - <name>MDimension Releases Repository</name>
73 + <id>wocommunity.releases</id>
74 + <name>WOCommunity Releases Repository</name>
41 41   <url>
42 - http://webobjects.mdimension.com/maven2/releases
76 + http://maven.wocommunity.org/content/groups/public
43 43   </url>
44 44   <releases>
45 45   <enabled>true</enabled>
... ... @@ -49,10 +49,10 @@
49 49   </snapshots>
50 50   </pluginRepository>
51 51   <pluginRepository>
52 - <id>mdimension.snapshots</id>
53 - <name>MDimension Snapshots Repository</name>
86 + <id>wocommunity.snapshots</id>
87 + <name>WOCommunity Snapshots Repository</name>
54 54   <url>
55 - http://webobjects.mdimension.com/maven2/snapshots
89 + http://maven.wocommunity.org/content/groups/public-snapshots
56 56   </url>
57 57   <releases>
58 58   <enabled>false</enabled>
... ... @@ -64,12 +64,11 @@
64 64   </pluginRepositories>
65 65   </profile>
66 66   </profiles>
67 - ...
68 68  </settings>
69 69  
70 70  {{/noformat}}
71 71  
72 -**NOTE**: You can download the complete settings.xml [[here>>^settings.xml]]. See [[Maven Settings Reference>>http://maven.apache.org/settings.html]] if you want more information about the settings.xml file.
105 +**NOTE**: You can download the complete and most recent settings.xml [[here>>^settings.xml]]. See [[Maven Settings Reference>>http://maven.apache.org/settings.html]] if you want more information about additional options for the settings.xml file.
73 73  
74 74  == Step 3: Installing WebObjects Libraries ==
75 75  
... ... @@ -83,6 +83,12 @@
83 83  
84 84  **NOTE**: WebObjects must be installed. See the [[maven-wobootstrap-plugin]] documentation for more information. See [[Maven Introduction to Repositories>>http://maven.apache.org/guides/introduction/introduction-to-repositories.html]] if you want more information about Maven repositories.
85 85  
119 +{{warning title="Installing the right jars!"}}
120 +
121 +Do *not* link to or install the WebObjects jars located inside {{/System/Library/Frameworks}} or {{/Library/Frameworks}}. If you're installing an older version of WebObjects you must obtain the jars that the WebObjects installer had previously installed into {{/Library/WebObjects/lib}}. For example, the jar {{/Library/WebObjects/lib/JavaWebObjects.jar}} has the complete set of resources and files included for the dependency JavaWebObjects whereas {{/System/Library/Frameworks/JavaWebObjects.framework/Resources/Java/javawebobjects.jar}} does not.
122 +
123 +{{/warning}}
124 +
86 86  == Step 4: Creating a WebObjects Project ==
87 87  
88 88  Archetypes are the fast way to create a new project using Maven. WOProject provides one archetype to create WebObjects Application. Execute the following command to generate a basic WebObjects project:
... ... @@ -90,9 +90,8 @@
90 90  {{noformat}}
91 91  
92 92  mvn archetype:generate -DarchetypeArtifactId=woapplication-archetype \
93 - -DarchetypeGroupId=org.objectstyle.woproject.maven2 \
94 - -DarchetypeVersion=2.0.16 \
95 - -DarchetypeRepository=http://webobjects.mdimension.com/maven2/releases
132 + -DarchetypeGroupId=org.objectstyle.woproject.maven2 \
133 + -DarchetypeVersion=2.0.17
96 96  
97 97  {{/noformat}}
98 98  
... ... @@ -125,8 +125,18 @@
125 125  
126 126  {{noformat}}
127 127  
128 -mvn clean install
166 +mvn clean package
129 129  
130 130  {{/noformat}}
131 131  
132 132  This goal will generate a WOA package inside the target folder of your project. It also generates two compressed packages: one for woapplication and other for the webserver resources.
171 +
172 +To install your project into your local repository:
173 +
174 +{{noformat}}
175 +
176 +mvn clean install
177 +
178 +{{/noformat}}
179 +
180 +This will install your project into ##,,/.m2/repository/your/project/groupId/artifactId/version/...,,##