Skip to content

Latest commit

 

History

History
60 lines (49 loc) · 2.62 KB

README.md

File metadata and controls

60 lines (49 loc) · 2.62 KB

ide-erlang package

Provides support of Erlang language for Atom IDE, using atom-languageclient and erlang_ls LSP server.

Currently in development.

Known and somewhat tested functions:

  • erlang_ls can be downloaded and compiled. It is not downloaded, if it was downloaded earlier.
  • erlang_ls is started. Communication through stdio only. Debug log is written to .cache/erlang_ls in Linux.
  • Goto declaration works for functions (even in other files).
  • Functions, that have specs get them displayed as a tooltip.

TODO list:

  • Make documentation (source) of dependencies available for erlang_ls.
  • Check the loading time. Currently the package almost freezes the computer for several seconds while the sources are being analysed. Maybe it is because of Atom dev environment? Can standard Erlang modules be indexed once and not every time Atom is started?
  • Check all the functions erlang_ls and Atom IDE can provide.
  • Maybe add some configuration possibilities.

Known bugs:

  • Sometimes when downloading server the following error appears:
      Error: unexpected end of file
    
    The following text appears in console:
      Uncaught (in promise) Error: unexpected end of file
          at Zlib.zlibOnError [as onerror] (zlib.js:166)
    
    It appears that the extraction is attempted before download is complete. However as far as I can see, the promises are handled correctly and debugging confirms it. If such situation occurs, server loading should be restarted.

References

This package is based on atom-languageclient.
It uses Language Server Protocol and erlang_ls server to provide its functionality.
The source code of ide-java package was used heavily to develop this package.

Disclaimer

I am not a very good JavaScript programmer. I am not familiar with Atom. And this is the first plug-in (package) I've ever written. So I will be very grateful for every constructive criticism and help with this project. I believe that Erlang is a fantastic language and it should be supported by Atom. I want to use Atom to develop my Erlang projects. Please, help me.

This work was inspired by a wonderful talk by erlang_ls author Roberto Aloi, called "Boost your productivity with the Erlang Language Server", in Code BEAM V conference on 11th September, 2020.