DEV Community


Posted on

Using Vim + SourceKit-LSP

My editor of choice has always been vim. Not because it's the best but probably because it's the one I've used the most. All the commands have been imprinted into my head from years of use. So it is no surprise that I would try to use SourceKit-LSP to have autocomplete and jump-to-definition for Swift files.

I wrote an article some months ago on the setup. But some people had trouble building SourceKit-LSP from the master branch.

So here is the solution if you are using Xcode11.

switch to the branch: swift-5.1-branch and build from that branch.

#In the directory where you cloned the SourceKit-LSP repo.
$ git fetch
$ git checkout swift-5.1-branch
$ swift build
Enter fullscreen mode Exit fullscreen mode

then everything should build correctly.

If you want to check the original article for the setup you'll find it here:

Top comments (0)