diff options
| author | Michael Lingelbach <m.j.lbach@gmail.com> | 2021-07-28 09:57:37 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-07-28 09:57:37 -0700 |
| commit | 3a47641125999cef15e7ac21d7590ed96686d00c (patch) | |
| tree | cc9fe52df08731779b762a84774cfdfd0acac775 /lua/lspconfig/efm.lua | |
| parent | [docgen] Update CONFIG.md (diff) | |
| download | nvim-lspconfig-3a47641125999cef15e7ac21d7590ed96686d00c.tar nvim-lspconfig-3a47641125999cef15e7ac21d7590ed96686d00c.tar.gz nvim-lspconfig-3a47641125999cef15e7ac21d7590ed96686d00c.tar.bz2 nvim-lspconfig-3a47641125999cef15e7ac21d7590ed96686d00c.tar.lz nvim-lspconfig-3a47641125999cef15e7ac21d7590ed96686d00c.tar.xz nvim-lspconfig-3a47641125999cef15e7ac21d7590ed96686d00c.tar.zst nvim-lspconfig-3a47641125999cef15e7ac21d7590ed96686d00c.zip | |
docs(efm): specify that filetypes must be set
Diffstat (limited to 'lua/lspconfig/efm.lua')
| -rw-r--r-- | lua/lspconfig/efm.lua | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/lua/lspconfig/efm.lua b/lua/lspconfig/efm.lua index 6a48690e..e5a81186 100644 --- a/lua/lspconfig/efm.lua +++ b/lua/lspconfig/efm.lua @@ -17,6 +17,18 @@ configs[server_name] = { https://github.com/mattn/efm-langserver General purpose Language Server that can use specified error message format generated from specified command. + +Note: In order for neovim's built-in language server client to send the appropriate `languageId` to EFM, **you must +specify `filetypes` in your call to `setup{}`**. Otherwise `lspconfig` will launch EFM on the `BufEnter` instead +of the `FileType` autocommand, and the `filetype` variable used to populate the `languageId` will not yet be set. + +```lua +require('lspconfig')['efm'].setup{ + settings = ..., -- You must populate this according to the EFM readme + filetypes = { 'python','cpp','lua' } +} +``` + ]], default_config = { root_dir = [[util.root_pattern(".git")(fname) or util.path.dirname(fname)]], |
