2
votes

Is there an equivalent of the Eclipse "Project" menu "Clean..." command in the Dart Editor? If not, how can a project be cleaned of the files generated by the various tools?

2
I think it would be a good idea to always add the dart tag as I guess most people just monitor this tag but not single specialized tags like dart-editor. - Günter Zöchbauer
Just in case you didn't know about it yet: There is a Dart Plugin for Eclipse. As you seem to be familiar with Eclipse, maybe that would suit you better than the standalone Dart Editor? - MarioP
@GünterZöchbauer: ok, will do (I was wondering about that). Thanks. - Patrice Chalin
@MarioP: yes thanks, I am aware of the plug-in, but I got the impression that it had less functionality. I wanted to post a question to get feedback from users who are working with the Eclipse plug-in and ask for comments/comparison to the Dart Editor, but such a question does not fit the Stackoverflow "How to Ask" criteria. - Patrice Chalin
@PatriceChalin Also, more relating to the question, Project>Clean is integrated nicely with the plugin. It triggers the build.dart two times, first with --clean (delete all generated files), followed by --full (full build) - MarioP

2 Answers

0
votes

Never heard of such a functionality in Dart.
What files of what tools? I guess from Run as JavaScript?
I guess the development goes in the direction that files are generated only in the build directory.
These files will be purged before rebuild.
But this is WIP.

0
votes

I have the same question. However I am coming to this question with a suggestion. I would like people to consider the build model implemented by Apache Maven for Dart builds.

The nice thing about the maven model is that you can:

  1. Define custom actions aside from the built-in ones.
  2. Implement custom handlers for actions.

As for the clean action in Eclipse -- Add my vote for Dart Editor.

Eclipse normally use either Apache Ant or Apache Maven for build actions. 'Clean' is a standard action and found its way to the Build menu at a very early stage. Which gives me an idea;

  • Add some UI meta-management to the Dart Editor
  • Build tool = Current Dart build (default), OR user specified: Ant, Maven, ...
  • Build menu = Set standard actions, allow custom actions against the current build tool; e.g. a "database load".

I know with new frameworks and languages there's always more things to do that time to do it. There are probably better examples than just And or Maven. I'm just pondering some flexible options to make the Dart development environment a little "future proof". ;-)