CompileProtege5InEclipseWithMaven

From Protege Wiki
Revision as of 12:25, August 2, 2013 by Tredmond (talk | contribs)

Jump to: navigation, search

Instructions for setting up Eclipse for working with Protege using maven

Under construction

Prerequisites

To follow these directions you will need the following tools:

  • Eclipse (of course) with
    • the Plugin Development tools included. As indicated here, the plugin development environment comes with the Java EE or the RCP/Plugin versions of eclipse.
    • the Eclipse Subversive plugin, though this is only required if you want to do svn updates using eclipse. Note that there is another similar but different plugin (from Tigris I believe). I don't know if these plugins interfere with one another if they are both loaded.
  • A tool for checking out a repository from subversion (e.g. tortoise or the svn command line client).
  • The maven build tool.

These directions are based on a preconfigured workspace which you can use for the build.

Configuring Eclipse

This is just one method of setting up eclipse and so feel free to adjust the approach to suit your preferences. When I first set up eclipse this way, I decided to have the Protege source tree be in a separate but parallel directory to the eclipse workspace. I decided that I like this arrangement because, as you will see, it ensures that the eclipse workspace files don't show up as modifications to the Protege source tree sources.

The first step in this process is to check-out the Protege sources. This can be done by checking out the svn tree (https://smi-protege.stanford.edu/repos/protege/protege4/misc/composite/protege5/trunk protege5). You can use any client that you like to perform the ckeck-out but for my command line client the command is as follows:

            svn checkout https://smi-protege.stanford.edu/repos/protege/protege4/misc/composite/protege5/trunk protege5

Now we build Protege using the maven command:

    cd protege5
    mvn install

This takes a little while

Running Protege

Add your own plugin