An Eclipse plugin client for ariatemplates/editor-backend
.
You can launch an Eclipse application with the plugin using an external backend (see procedure below) and use it to edit files with .tpl
extension: despite the name of the extension only the HTML syntax will be supported inside! (this remains to be fixed...)
.gitignore
: Git related filestatics
: folder containing some tools for developmentbin
: folder containing the build of the plugin
Documentation:
README.md
: this current fileroadmap.md
: a roadmap for the project
Code:
src
: the sources of the Eclipse pluginbuild.properties
,plugin.xml
,META-INF
: files and folders contributing to the Eclipse plugin definition.project
,.classpath
,.settings
: files related to the Eclipse project configuration
What might be versioned (should be reproducible but might differ between environments - so versioning could pollute more than help):
.project
,.classpath
,.settings
To ignore:
bin
: generated content (from the sources)
To version: everything else.
First of all: READ CAREFULLY THE DOCS.
Please have a look at the documentation of the documentation too (we follow the same rules as for the backend project).
To be able to develop the project or even use the product you need to:
- Install Eclipse IDE - tested with latest version (Kepler at the time of writing)
- Preferably choose Java EE bundle
- Install the plugin Google GSON from Orbit repository (latest at the time of writing)
- Have a Java SE installation available - tested with latest version (7 at the time of writing)
Tested on Microsoft Windows 7 Enterprise 64-bit SP1.
After cloning the repository
git clone https://github.com/ariatemplates/editor-frontend-eclipse.git
you will have to do some setup.
There are two items to setup: the backend and the Eclipse project.
Please see the backend project's documentation for setup procedure.
__DISCLAIMER: the following feature is broken: __
You can theoretically put it anywhere, since it communicates through network, but if you install it in a resources
folder inside the root of this project, the plugin should be able to launch the backend automatically if not running already.
Here is the full detailed procedure to create the Eclipse project from the sources:
- Create a new project inside this current folder:
- From the main menu
File>New>Other...
, selectProject
under categoryGeneral
- Give it any name you want
- Uncheck the checkbox
Use default location
- Browse the file system to select this current folder
- Click on
Finish
- From the main menu
- Add natures to the project:
- open externally the generated
.project
file under the root folder of the project (i.e. this current folder): this file is in XML format - under the XML element
natures
, add natures by addingnature
elements (example:<natures><nature>org.eclipse.pde.PluginNature</nature></natures>
) - add the following natures:
org.eclipse.pde.PluginNature
org.eclipse.jdt.core.javanature
- Refresh the project (select it and press
F5
by default, or click onRefresh
in its context menu)
- open externally the generated
- Edit properties of the project:
- Open properties of the project by choosing menu
Project>Properties
(orProperties
from contextual menu of the project with right-click on it in) - Configure build path
- Select
Java Build Path
in the sidebar - Select tab
Source
in the right panel- Click on
Add Folder...
- Check:
resources
(if you used it to install the backend)src
(if not already selected)
- Note that the file
plugin.xml
and the folderMETA-INF
don't have to be explicitely added
- Click on
- Select tab
Libraries
- Click on
Add Library...
- Select
Plug-in Dependencies
- Click
Next
thenFinish
- Click on
- Select
- Add builders
- open externally the
.project
file - under the element
buildSpec
, add builders by addingbuildCommand
elements, each of them containing two elements:name
andarguments
(example:<buildSpec><buildCommand><name>org.eclipse.jdt.core.javabuilder</name></buildCommand></buildSpec>
) - add the following builders in order (just put the following in
name
elements):org.eclipse.jdt.core.javabuilder
org.eclipse.pde.ManifestBuilder
org.eclipse.pde.SchemaBuilder
- Refresh the project (select it and press
F5
by default, or click onRefresh
in its context menu)
- open externally the
- Open properties of the project by choosing menu
For simplicity, here is for the .project
file the XML snippet resulting from the above procedure ( this is not the whole file!! ):
<buildSpec>
<buildCommand><name>org.eclipse.jdt.core.javabuilder</name></buildCommand>
<buildCommand><name>org.eclipse.pde.ManifestBuilder</name></buildCommand>
<buildCommand><name>org.eclipse.pde.SchemaBuilder</name></buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.pde.PluginNature</nature>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
For the following, default values should be fine:
- the build target should go in a
bin
folder, to be compliant with the versioning - ignoring patterns. - the Java compliance should be set to the Java version corresponding to the one used (see previous section).
- Launch the backend (see project)
- Launch the Eclipse application
- Open the Eclipse project
- Launch the project as an Eclipse application
- Select the project and select menu
Run>Run As
orRun>Debug As
, or use the contextual menu of the project and respectively selectRun As
orDebug As
- Choose
Eclipse Application
- Select the project and select menu
Then you can start editing files with the .tpl
extension under a new project.
Please refer to the subfolders of the project for details about corresponding modules specific development: every folder containing a documentation like this contains a section talking about contributions you can make to it.
Sections below discuss about development at the whole project scale.
Please have a look at the roadmap too for a prioritization of what has to be done. It will link to specific documentations' sections.
Clean Eclipse extension points.
Do we use the
org.eclipse.ui.editors.documentProviders
extension point or not?
We can manage without, as it is done for now, but maybe it's better for design purposes to use it.