To enable Swift language support in your IDE, you can integrate SourceKit-LSP.
-
Install Swift. Please see the Getting Started Guide on Swift.org for details on how to install Swift on your system. This installation will install the SourceKit-LSP language server.
-
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.
-
Select SourceKit-LSP as the template from the available options. This will populate the command field with a default command
sourcekit-lsp
-
Optional: You may also customize the mappings section according to your preferences.
-
Click OK to apply the changes. You should now have Swift language support enabled in your IDE.
If you need to Run/Debug Go program, you can configure the Swift LLDB DAP server.