8000 feature: emmylua-analyzer support · Issue #86 · folke/lazydev.nvim · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

feature: emmylua-analyzer support #86

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
1 task done
Saghen opened this issue Jan 22, 2025 · 10 comments · May be fixed by #96
Open
1 task done

feature: emmylua-analyzer support #86

Saghen opened this issue Jan 22, 2025 · 10 comments · May be fixed by #96
Labels
enhancement New feature or request

Comments

@Saghen
Copy link
Saghen commented Jan 22, 2025

Did you check the docs?

  • I have read all the lazydev.nvim docs

Is your feature request related to a problem? Please describe.

One of the developers for lua-language-server has published a rust re-implementation, called emmylua-analyzer.

Describe the solution you'd like

It uses a different format for its configuration, but afaict, it supports the same workspace.library as lua-language-server. Currently, it only makes the workspace/configuration request when it detects VSCode, and it doesn't support setting the workspace.library from the workspace/configuration call. I've opened an issue about these in the emmylua-analyzer repo: EmmyLuaLs/emmylua-analyzer-rust#6

Given support is added, would you be interested in supporting it?

Describe alternatives you've considered

Creating a separate plugin specifically for emmylua-analyzer but I feel this would cause unnecessary fragmentation

Additional context

No response

@Saghen Saghen added the enhancement New feature or request label Jan 22, 2025
@folke
Copy link
Owner
folke commented Jan 23, 2025

Interesting for sure!
When that config gets added, I'll see to add support.

@folke
Copy link
Owner
folke commented Jan 23, 2025

Added very basic support. Pretty sure it won't work as is though :)

Didn't test it either. Would be great to have it in lspconfig so it's easier to test.

@dsully
Copy link
dsully commented Feb 7, 2025

FWIW, I'm testing with a lsp/emmylua_ls.lua file and returning a vim.lsp.Config that feeds into:

vim.lsp.config("*", {
    root_markers = { ".git" },
})

local should_enable = require("helpers.lsp").should_enable

vim.iter(vim.api.nvim_get_runtime_file("lsp/*.lua", true))
    :map(function(config_path)
        return vim.fs.basename(config_path):match("^(.*)%.lua$")
    end)
    :each(function(server_name)
        vim.lsp.enable(server_name, should_enable(server_name))
    end)

Copy link
Contributor

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@github-actions github-actions bot added the stale label Mar 10, 2025
@Saghen
Copy link
Author
Saghen commented Mar 10, 2025

Not stale

@FelipeLema
Copy link

note: ${3rd}/luv/library doesn't make sense in emmylua because the code/repo is not included like with lua-language-server

you'll have to download https://github.com/LuaCATS/luv and provide the corresponding path to emmyrc's workspace.library instead

Copy link
Contributor

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@github-actions github-actions bot added the stale label Apr 14, 2025
@Saghen
Copy link
Author
Saghen com 8000 mented Apr 14, 2025

Not stale

@github-actions github-actions bot removed the stale label Apr 15, 2025
@mikavilpas
Copy link

Looks like this LSP has been added to nvim-lspconfig here neovim/nvim-lspconfig#3745

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants
0