Skip to content

Latest commit

 

History

History
25 lines (14 loc) · 1.74 KB

metals.md

File metadata and controls

25 lines (14 loc) · 1.74 KB

To enable Scala language support in your IDE, you can integrate Scala Language Server (Metals) by following these steps:

Metala LS demo

  1. Install Coursier and read How to start Metals?.

  2. Once Coursier is installed, open a terminal and execute coursier bootstrap org.scalameta:metals_2.13:1.2.2 -o metals -f which will generate ${BASE_DIR}/metals and ${BASE_DIR}/metals.bat (according your OS).

  3. Open the New Language Server Dialog. This can usually be found under the IDE settings related to Language Server Protocol (LSP). For more information, refer to the New Language Server Dialog documentation.

  4. Select Scala Language Server (Metals) as the template from the available options. This will populate the command field with a default command. You need to adjust this command to point to the location of the extracted generated ${BASE_DIR}/metals.bat file.

    Metals template

  5. Adjust the command in the template to reference the location of the generated metals file.

  6. Optional: You may also customize the mappings section according to your preferences.

    Meta LS template mappings

  7. Click OK to apply the changes. You should now have Scala language support enabled in your IDE, with the Metals integrated.

    Meta LS in LSP Console