gemoc / ale-lang

Action Language for EMF
Eclipse Public License 1.0
8 stars 6 forks source link

Automatically validate project when the ALE environment changes #183

Open echebbi opened 4 years ago

echebbi commented 4 years ago

Motivation

Validators are only triggered when making changes in the editor. However, adding/removing source files or metamodels from the preferences/.dsl should also trigger new validations.

Proposed Solution

Detect when the ALE environment changes and programmatically trigger a new Xtext validation every time.

Proposed Implementation

Not sure about the best implementation; I see two possibilities:

dvojtise commented 4 years ago

I usually like to have a project nature with project builder, they are quite easy to implement and as a user it is also easy to add/remove the nature on a given project (for example in order to add ale nature to an ecore modelling project when adding ale file in it), It is also convenient for a user to do a "clean all" in order to launch all validations and compilations (a couple of resource/preference listener doesn't allow that)