guillermooo / dart-sublime-bundle

Sublime Text 3 Dart Package
BSD 3-Clause "New" or "Revised" License
264 stars 42 forks source link

integrate with dart_style #490

Open guillermooo opened 9 years ago

guillermooo commented 9 years ago

It seems to be ready for general use:

https://pub.dartlang.org/packages/dart_style

guillermooo commented 9 years ago

If we find dartfmt in an sdk subdir, warn users that they should be using dart_style.

@sethladd Is dart_style going to remain as pub package meant to be installed via 'pub global'. Or is it planned to be included in the SDK?

jwren commented 9 years ago

Since you have integrated with the Analysis Server already, you could get the formatting through the server API:

http://htmlpreview.github.io/?https://github.com/dart-lang/bleeding_edge/blob/master/dart/pkg/analysis_server/doc/api.html#request_edit.format

guillermooo commented 9 years ago

Oh, wow, didn't know that... I'm falling behind! :)

Thanks!

guillermooo commented 9 years ago

I've just noticed that the new dartfmt's command line options are compatible with the sdk's version, though, so users that have the new one installed can already use it now. That's a good stop-gap solution until I get around to implementing the formatting through the server.