TelluIoT / ThingML

The ThingML modelling language
https://github.com/TelluIoT/ThingML
Apache License 2.0
101 stars 32 forks source link

Toolbar and keyboard shortcuts for generating code in Eclipse #226

Open jakhog opened 6 years ago

jakhog commented 6 years ago

While writing ThingML models in Eclipse, the process of finding the right file with the configuration -> right-click -> ThingML -> Select compiler, is tedious and slightly annoying (if you click the wrong button).

IMO, there are two alternatives to improve this situation:

  1. Having "Run Configurations" like other languages have in Eclipse. I see there is already something there for ThingML, but it is not working. This would make it behave a lot like other languages, and would make it possible use keyboard shortcuts for generating code.

  2. Making a separate toolbar and custom keyboard shortcut for generating platform code. This should have a dropdown for selecting a configuration (in the current project directory), and one for selecting the target compiler.

I'm not sure which one I like the most. But I'm leaning a bit towards 2. That could make it very easy to have one button for generating platform code with one keyboard shortcut, and using the normal (F10?) to run the platform code.

ffleurey commented 6 years ago

Agreed that something needs to be done about this.

However, in terms of choosing the compiler (or series of compiler calls) to make in order to build a project I would prefer putting annotations in the thingml which specify which compiler (or tool) to be used. Then it becomes just a matter of calling the ThingML compiler and it figures out what it has to do. The good thing is that in eclipse it become just on click (no multiple choice) and in the command line it would work exactly the same.