diff options
| author | Denis Mitana <denis.mitana1@gmail.com> | 2021-12-02 16:17:02 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-12-02 07:17:02 -0800 |
| commit | f2c2d5e889da602518404604da3c7116347a3f3e (patch) | |
| tree | c2e01692d46d64acae57556244fb82d656a3673a /lua | |
| parent | docs: update server_configurations.md (diff) | |
| download | nvim-lspconfig-f2c2d5e889da602518404604da3c7116347a3f3e.tar nvim-lspconfig-f2c2d5e889da602518404604da3c7116347a3f3e.tar.gz nvim-lspconfig-f2c2d5e889da602518404604da3c7116347a3f3e.tar.bz2 nvim-lspconfig-f2c2d5e889da602518404604da3c7116347a3f3e.tar.lz nvim-lspconfig-f2c2d5e889da602518404604da3c7116347a3f3e.tar.xz nvim-lspconfig-f2c2d5e889da602518404604da3c7116347a3f3e.tar.zst nvim-lspconfig-f2c2d5e889da602518404604da3c7116347a3f3e.zip | |
fix(eslint): openDoc function on Linux (#1529)
Now the `open` command is used to execute eslint's `openDoc` function,
but `xdg-open` is the default command in Linux used to open a file or
URL in the user's preferred application.
Diffstat (limited to 'lua')
| -rw-r--r-- | lua/lspconfig/server_configurations/eslint.lua | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lua/lspconfig/server_configurations/eslint.lua b/lua/lspconfig/server_configurations/eslint.lua index 06658f30..5ddd3b4a 100644 --- a/lua/lspconfig/server_configurations/eslint.lua +++ b/lua/lspconfig/server_configurations/eslint.lua @@ -110,6 +110,8 @@ return { local sysname = vim.loop.os_uname().sysname if sysname:match 'Windows' then os.execute(string.format('start %q', result.url)) + elseif sysname:match 'Linux' then + os.execute(string.format('xdg-open %q', result.url)) else os.execute(string.format('open %q', result.url)) end |
