xcode-build-server: LSP doesn't come with code completions/suggestions

Hello, i haven’t code completions/suggestions while my LSP is successfully activate and i’ve generate buildServer.json in the root of my working directories. Here are some screenshoots for my problem:

  • I want to integrate SourceKit-LSP with my NeoVim, and here are my configurations: Screenshot 2024-01-28 at 09 33 12

  • Here are my cloned xcode-build-server repos: Screenshot 2024-01-28 at 09 34 17

  • Here are my generated buildServer.json Screenshot 2024-01-28 at 09 35 33

  • Here are my working directories Screenshot 2024-01-28 at 09 36 12

  • Here are my LspLog when i open my Swift file: Screenshot 2024-01-28 at 09 38 10

  • I try to type import and Lsp doesn’t give anything about suggestions/completions: Screenshot 2024-01-28 at 09 37 29

So, that’s my report for you. I hope i can develop iOS app outside XCode environment. Thank you very much for your great work, mate 🍻

About this issue

  • Original URL
  • State: closed
  • Created 5 months ago
  • Comments: 25 (12 by maintainers)

Most upvoted comments

I try available suggestions, and this is what i get.

  • I try to run the default test when i create the project: Screenshot 2024-02-06 at 16 28 54

  • I try to re-generate buildServer.json: Screenshot 2024-02-06 at 16 37 22

  • I try to re-open NeoVim and try to import xct and code completions/suggestions shows up: Screenshot 2024-02-06 at 16 33 21

  • I try to import inje and code completions/suggestions shows up: Screenshot 2024-02-06 at 16 38 01

  • I try to use Inject in code, and code completions/suggestions shows up: Screenshot 2024-02-06 at 16 38 51 Screenshot 2024-02-06 at 16 39 05

  • I try to use gd when the cursor above Inject as for Goto Definition in NeoVim: Screenshot 2024-02-06 at 16 39 35

And i think finally it works really perfect. Should i close the issue?

I have been experimenting with the Xcode-Build-Server project using Helix editor and have noticed an interesting behavior regarding LSP suggestions. When creating Xcode projects (Xcode 15.2 (15C500b), Ventura 13.6.1) with the ‘create git repo on my mac’ option selected, LSP suggestions work perfectly. However, if I disable this option and create the project without a git repository, LSP suggestions do not work. I have verified that all paths are correct and have tested with other projects, but the behavior persists. Interestingly, if I create a project with git disabled and then create a repo with git init, LSP suggestions start working.

I thought this information might be helpful to others who are using the Xcode-Build-Server project and experiencing similar issues.

I think this works very perfect, and i’ve try to maximize the potentials to see great articles from @wojciech-kulik again.

Thank you very much, for all of you. Keep your great works, and enjoy your life, mate 🍻