eclipse-null-eea-augments icon indicating copy to clipboard operation
eclipse-null-eea-augments copied to clipboard

How to make EEA easier to review, diff & merge

Open vorburger opened this issue 6 years ago • 14 comments

While working on https://github.com/lastnpe/eclipse-null-eea-augments/issues/10 and merging some EEA java.* from an existing project (tracecompass) with some EEA I had already created in this project before, I realized that diff & merge of *.eea is quite a PITA... e.g. Git is often wrong and would have lost things, because it's algorithm for finding dupes assume you want to change things when really you want to add.

As (or perhaps even more...) important than diff & merge is simple "review-ability" - unless you are really used to the EEA syntax (which e.g. I currently am not yet..), it's kind of really hard actually to immediately understand exactly what gets changed in e.g. something like the Map get() and remove() of PR https://github.com/lastnpe/eclipse-null-eea-augments/pull/21.

The goal of this issue to collect community feedback is there's anything that can be done to help with this:

  • Git settings for *.eea ?!
  • Minor changes to the EEA file format (probably too late already)
  • Alternative friendlier syntax with generator/converter to EEA?

@svenefftinge once suggested the idea of an Xtext grammar for this... that could be cool, some day! ;-) Imagine representing EEA as a very Java-like Xbase validating DSL language, with the respective @Nullable etc. annotations as if it was Java (but without any Method bodies), and then a little EEA generator off that - that could be neat. BUT one problem that deserves more thought before jumping into such a DSL (which isn't really THAT hard to put together...) is the workflow... The Eclipse IDE integration using which developers maintain EEA files directly (which is how EEA get created today) would become much MORE cumbersome - after you Quick Fix an EEA, how do you get the EEA changed? In ideal world, that would have to be some fancy bi-directional thingie - but that's a little less immediate easy like pie out of the box, e.g. with Xtext.

vorburger avatar Sep 15 '17 00:09 vorburger