Getting started

Last modified by Maik Musall on 2021/06/16 09:17

Foreword

Since the rest of this page is old (2010), please consult Hugis gists:

Introduction

This guide is aimed at those who'd like to set up a local wolips development environment. This guide is mainly targeted towards maven users of WOLips, however much of guide is useful, whether you use maven or ant, so far as installation instructions for eclipse plugins. At least, these are the steps that I (ldeck) travel through and it is essentially a brain-dump to save me from future maintenance work .

Outline

Install Maven

You can download and install maven for most platforms here.

Success

Mac Tip

install macports http://www.macports.org/install.php, then on the terminal


Unknown macro: noformat. Click on this message for details.


In future, to keep this up to date:


Unknown macro: noformat. Click on this message for details.


Download Eclipse

Eclipse can be downloaded and installed from www.eclipse.org/downloads/. For mac it's just a simple matter of unpacking the zip file downloaded into /Applications or /Users/youraccount/Applications.

Success

Which one do I choose?

Eclipse Classic (161MB) is a popular choice among WO developers.
However, the more lightweight Eclipse IDE for Java Developers (91MB) should work.

Launch Eclipse

Open eclipse by double clicking on the application icon (from where you installed it).
LaunchEclipse.png

Eclipse will then ask you for the location of a 'workspace' which is where eclipse will store its metadata.
LaunchEclipseWorkspace.png

Install Eclipse plugins

Various plugins have prerequisites, and some are just useful anyway, so here's a suggested order of installing some useful plugins when setting up a brand new eclipse environment.

Step 1 - Choose the menu item: Help > install new software...

install_menu.png

This will open the install window:
install_window.png

Step 2 - install the testNG plugin (for a simple example)

a) Click the "Add..." button to define the update site, fill in the details, click OK.

addsite_testng.png

b) Tick the plugin fragments to install

fragments_testng.png

c) Click next repeatedly, confirming license agreements, finally clicking "Finish" to install.
d) after the software plugin has installed, it will prompt you for a restart of eclipse. Click Yes.

install_restart.png

e) after eclipse has restarted, continue...

Step 3 - install Groovy

Repeat step 2 with the following detail changes:
Site name: Groovy-dev
Site location: http://dist.codehaus.org/groovy/distributions/updateDev/

Step 4 - Install subversive connectors

Repeat step 2 with the following detail changes:
Site name: Subversive-connectors
Site location: http://community.polarion.com/projects/subversive/download/eclipse/2.0/galileo-site/
Fragments selected: 'Subversive SVN Connectors', 'SVNKit 1.3 Implementation (Optional)'

fragments_subversive.png

Step 5 - Install egit

Repeat step 2 with the following detail changes:
Site name: egit
Site location: http://www.jgit.org/updates

Step 6 - Install m2eclipse

Repeat step 2 with the following detail changes:
Site name: m2eclipse
Site location: http://m2eclipse.sonatype.org/sites/m2e
Fragments selected: "Maven Integration for Eclipse (Required)"
fragments_m2e_lmg.png

Step 6 - Install WOLips

Choose an update site that's appropriate for the version of Eclipse you're running. The update site for Eclipse 3.5 is as follows. (Ask on the mailing list for future versions if it's not been updated here).

Repeat step 2 with the following detail changes:
Site name: WOLips_3_5
Site location: http://webobjects.mdimension.com/wolips/eclipse_3_5/
Fragments selected: all "Standard Install" components
fragments_wolips.png

Step 7 - Other plugins

Oh, sure I also install jadclipse (http://jadclipse.sf.net/update) for keeping in touch with things but that's beyond the scope of this guide.

Configuring Eclipse

wolips binding validation

wolips_bindingsvalidation.png

wolips spaces around html tags

wolips_nospaces.png

wolips launching

As of this writing, wolips has forgotten to set the key "-WOHost" with value "localhost". Add it.
I also untick a few things that don't need to be specifically ticked so that your project's properties are used (as you're mimicking the deployment env locally)
wolips_launching.png

Set the default jvm

prefs_jvm.png

Java typing prefs

prefs_java_typing.png

Java Templates prefs

prefs_java_templates.png

Run / Debug prefs

I'll have 4 spaces per tab rather than 8 thanks!
And I prefer to kill the console buffer manually rather than lose messages that might be important.
prefs_console.png

Launch configurations

I don't like them disappearing on me when I close / delete projects
prefs_launchconfig.png

Lines numbers please

prefs_linenumbers.png

UTF-8 Thanks

prefs_utf8.png

Creating a project

TODO

Launching your project

Configure eomodel connection dictionaries, log4j, additional properties

In my application projects I create an additional folder called 'Properties' which contains additional property files for differing launches.
e.g.,
When connecting to a local database I use the local files listed below during launch:

Unknown macro: noformat. Click on this message for details.

To achieve this switching easily I define in the launch configuration for the application the following two additional properties (from those defined globally in WOLips prefs)

  • key: -runtime.config.dir value:"../../Properties"
  • key: -runtime.config.name value:".local"

And in my application's Properties file I have the following properties declared

Unknown macro: noformat. Click on this message for details.

Naturally, within the jdbc property files are the relevant project wonder properties for configuring the eomodels connection dictionaries, withing the lo4j files are the relevant config for log4j, and runtime properties is available for any special configuration for that particular environment.