Changes for page Quick Start

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

From version 36.1
edited by Lachlan Deck
on 2008/11/23 15:41
Change comment: Adjusting settings example so as to be immediately pasted into file to use
To version 24.1
edited by Lachlan Deck
on 2011/08/13 22:15
Change comment: There is no comment for this version

Summary

Details

Page properties
Content
... ... @@ -1,3 +1,5 @@
1 +== Outline ==
2 +
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.
... ... @@ -4,73 +4,24 @@
4 4  
5 5  {{tip title="Mac Tip"}}
6 6  
7 - install macports [http://www.macports.org/install.php], then on the terminal
8 - {noformat}sudo port install maven2{noformat}
9 +install macports [http://www.macports.org/install.php], then on the terminal{noformat}sudo port install maven3{noformat}
9 9  
10 - In future, to keep this up to date:
11 - {noformat}sudo port upgrade maven2{noformat}
11 +In future, to keep this up to date:{noformat}sudo port upgrade maven3{noformat}
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.
15 +**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.,,
19 +Advanced users can skip this step, but it's highly recommended.
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:
21 +[[Quick Start Maven Settings Configuration Guide]]
22 22  
23 -{{noformat}}
23 +**NOTE for those who know what to do**: You can download the complete and most recent settings.xml [[here>>^settings.xml]] and install it to /.m2/settings.xml.
24 24  
25 -<settings xmlns="http://maven.apache.org/POM/4.0.0"
26 - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
27 - xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
28 - http://maven.apache.org/xsd/settings-1.0.0.xsd">
29 - <pluginGroups>
30 - <pluginGroup>org.objectstyle.woproject.maven2</pluginGroup>
31 - </pluginGroups>
32 - <profiles>
33 - <profile>
34 - <id>woproject</id>
35 - <activation>
36 - <activeByDefault>true</activeByDefault>
37 - </activation>
38 - <pluginRepositories>
39 - <pluginRepository>
40 - <id>mdimension.releases</id>
41 - <name>MDimension Releases Repository</name>
42 - <url>
43 - http://webobjects.mdimension.com/maven2/releases
44 - </url>
45 - <releases>
46 - <enabled>true</enabled>
47 - </releases>
48 - <snapshots>
49 - <enabled>false</enabled>
50 - </snapshots>
51 - </pluginRepository>
52 - <pluginRepository>
53 - <id>mdimension.snapshots</id>
54 - <name>MDimension Snapshots Repository</name>
55 - <url>
56 - http://webobjects.mdimension.com/maven2/snapshots
57 - </url>
58 - <releases>
59 - <enabled>false</enabled>
60 - </releases>
61 - <snapshots>
62 - <enabled>true</enabled>
63 - </snapshots>
64 - </pluginRepository>
65 - </pluginRepositories>
66 - </profile>
67 - </profiles>
68 -</settings>
25 +See [[Maven Settings Reference>>http://maven.apache.org/settings.html]] if you want more information about additional options for the settings.xml file.
69 69  
70 -{{/noformat}}
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.
73 -
74 74  == Step 3: Installing WebObjects Libraries ==
75 75  
76 76  Maven takes control of all your project's dependencies. To develop WebObjects applications, Maven has to reference the WebObjects jars. You have to install the WebObjects libraries into your local repository to accomplish this:
... ... @@ -81,8 +81,18 @@
81 81  
82 82  {{/noformat}}
83 83  
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.
37 +**NOTE**: WebObjects must be installed.
85 85  
39 +**See** the [[maven-wobootstrap-plugin>>maven-wobootstrap-plugin]] documentation for more information and options for specifying a specific version.
40 +
41 +**See** [[Maven Introduction to Repositories>>http://maven.apache.org/guides/introduction/introduction-to-repositories.html]] if you want more information about Maven repositories.
42 +
43 +{{warning title="Installing the right jars!"}}
44 +
45 +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.
46 +
47 +{{/warning}}
48 +
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,15 +90,14 @@
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
56 + -DarchetypeGroupId=org.objectstyle.woproject.maven2 \
57 + -DarchetypeVersion=2.0.17
96 96  
97 97  {{/noformat}}
98 98  
99 99  The maven-archetype-plugin will ask the required information to create the new project.
100 100  
101 -**NOTE**: You can use archetype catalogs to reduce the number of properties to set while creating a project. See the documentation of [[woapplication-archetype]].
63 +**NOTE**: You can use archetype catalogs to reduce the number of properties to set while creating a project. See the documentation of [[woapplication-archetype>>woapplication-archetype]].
102 102  
103 103  **NOTE**: You can use archetypes within Eclipse as described [[here>>Maven Create WO Application Project||anchor="m2eclipse"]].
104 104  
... ... @@ -125,8 +125,18 @@
125 125  
126 126  {{noformat}}
127 127  
128 -mvn clean install
90 +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.
95 +
96 +To install your project into your local repository:
97 +
98 +{{noformat}}
99 +
100 +mvn clean install
101 +
102 +{{/noformat}}
103 +
104 +This will install your project into ##/.m2/repository/your/project/groupId/artifactId/version/...##