Open robertoaloi opened 4 years ago
Noted. I should be able to detect whether we're started in API mode or not and adapt output accordingly.
Also, the Build Server Protocol has an initialized
notification that can be used "to initialize intensive computation such as dependency resolution or compilation. The initialized notification may only be sent once."
Something we could leverage. See: https://build-server-protocol.github.io/docs/specification#initialized-build-notification
In case of a compilation error, the error is currently printed out via
rebar_api:info/2
and thenrebar_api:abort/0
is called. From a Language Server perspective, where the plugin is not invoked from command line, but via the Erlang API:It would be much more convenient to obtain the compiler errors in raw format, so they can be published as diagnostics.
Also see the els_compiler_diagnostics module to see how compiler results are currently converted to diagnostics in Erlang LS.