From d50ed66979678bd9aff294bb2ff5c826fa4a390e Mon Sep 17 00:00:00 2001 From: "john.j.camilleri" Date: Mon, 11 Jun 2012 08:15:35 +0000 Subject: [PATCH] GFEP: updated readme --- eclipse/index.html | 62 +++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 59 insertions(+), 3 deletions(-) diff --git a/eclipse/index.html b/eclipse/index.html index e855f9181..c78c98e30 100644 --- a/eclipse/index.html +++ b/eclipse/index.html @@ -157,7 +157,7 @@ Updated: 1 June 2012

  • Add the GF perspective by clicking Window → Open Perspective → Other and choosing GF.
  • The plugin will try to determine the path to your GF executable automatically. You can check/overwrite it by going to Preferences → Grammatical Framework. This path should include the name of the GF binary itself, e.g. /home/john/.cabal/bin/gf or C:\Users\John\GF\gf.exe.
  • -
  • By default, the Library path setting is set to .:present:alltenses:prelude. This is passed to GF using the --path flag.
  • +
  • By default, the Library path setting is set to .:alltenses:prelude. This is passed to GF using the --path flag.
  • You can also adjust the verbosity level of the GFEP console log in the preferences window.
  • @@ -416,11 +416,11 @@ Each time you save a file (or some other change occurs in your project), the bui

    GFEP attempts to compile all of your files individually with GF, which is not the usual way in which you would compile your grammar. As a result, when looking for the RGL files, GF needs a little help via the path argument.

    -

    The normal way to do this is to specify the Library path setting from Preferences → Grammatical Framework, setting it to something like .:present:alltenses:prelude (this is the default setting). Note that these paths are relative to the true RGL directory, which GF should already be aware of. The value of this setting is passed to GF from GFEP using the --path flag.

    +

    The normal way to do this is to specify the Library path setting from Preferences → Grammatical Framework, setting it to something like .:alltenses:prelude (this is the default setting). Note that these paths are relative to the true RGL directory, which GF should already be aware of. The value of this setting is passed to GF from GFEP using the --path flag.

    The Library path setting is the same for all your GF projects. If you want finer-grain control over the path compiler option then you should use compiler pragmas in your source files, e.g.:

    -
    --# -path=.:present:alltenses:prelude
    +
    --# -path=.:alltenses:prelude
     

    The advantage of this method is that the information is bound to the file, so you can freely compile your modules outside of GFEP without having to specify the path as a command line option to GF. @@ -435,6 +435,62 @@ I only support the latest version of the plugin, so make sure you are up to date +

    For developers

    + +

    Project setup

    + +

    In order to build/run the GFEP from source, you need to have the Xtext libraries available in your Eclipse workspace. You have two choices:

    + +
      +
    1. Download the Xtext libraries from http://www.eclipse.org/Xtext/download/ and add them to your existing Eclipse instance
    2. +
    3. Download a release of Eclipse packaged together with Xtext from http://xtext.itemis.com/xtext/language=en/36553/downloads
    4. +
    + +

    In both cases make sure you get the correct version of Xtext (see below). +Once you have Xtext set up, you can clone the repository locally with git clone git://github.com/GrammaticalFramework/gf-eclipse-plugin.git and then add the projects under the workspace directory to your Eclipse workspace.

    + +

    Xtext version

    + +

    GFEP currently uses Xtext 2.1.0.

    + +

    Running from source

    + +

    Once you have set up your projects (see above), you can run/debug the GFEP by following the steps here. +Note that this means you will be running two instances of Eclipse simultaneously; the first debugging the second.

    + +

    Building plugin package

    + +

    To package the GFEP sources as .jar files and install/update the GFEP in a separate Eclipse installation, do the following:

    + +
      +
    1. Right-click on the project org.grammaticalframework.feature and choose Export…
    2. +
    3. Select Plug-in Development → Deployable features
    4. +
    5. Use the following options: + +
        +
      • Available features: org.grammaticalframework.feature (x.y.z.qualifier)
      • +
      • Destination + +
          +
        • Directory: <local directory>
        • +
      • +
      • Options + +
          +
        • Package as individual JAR archives + +
            +
          • Generate metadata repository
          • +
          • Categorize repository: <workspace>/org.grammaticalframework.feature/category.xml
          • +
        • +
        • Allow for binary cycles in target platform
        • +
      • +
    6. +
    7. Click Finish and wait for the plugin to build. You may get some errors, in which case look through the generated log.zip and fix them, then repeat the process.
    8. +
    + + +

    Evaluation & feedback

    Please try to use the plugin for developing your own GF projects and report any issues you come up against.