diff options
| author | Michael Lingelbach <m.j.lbach@gmail.com> | 2021-05-01 11:11:19 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-05-01 11:11:19 -0700 |
| commit | 6e48e492432b241652ab0bb5d6a2acf89f5bda55 (patch) | |
| tree | 726164bd042ed4851d4f32811ac0b5a810f7802d /lua/lspconfig/util.lua | |
| parent | Merge pull request #864 from nanotee/zeta_note (diff) | |
| parent | Use dofile instead of require for faster setup({}) (diff) | |
| download | nvim-lspconfig-6e48e492432b241652ab0bb5d6a2acf89f5bda55.tar nvim-lspconfig-6e48e492432b241652ab0bb5d6a2acf89f5bda55.tar.gz nvim-lspconfig-6e48e492432b241652ab0bb5d6a2acf89f5bda55.tar.bz2 nvim-lspconfig-6e48e492432b241652ab0bb5d6a2acf89f5bda55.tar.lz nvim-lspconfig-6e48e492432b241652ab0bb5d6a2acf89f5bda55.tar.xz nvim-lspconfig-6e48e492432b241652ab0bb5d6a2acf89f5bda55.tar.zst nvim-lspconfig-6e48e492432b241652ab0bb5d6a2acf89f5bda55.zip | |
Merge pull request #861 from mjlbach/dofile
Use dofile instead of require for faster loading
Diffstat (limited to 'lua/lspconfig/util.lua')
| -rw-r--r-- | lua/lspconfig/util.lua | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lua/lspconfig/util.lua b/lua/lspconfig/util.lua index dc06f181..5c45a78c 100644 --- a/lua/lspconfig/util.lua +++ b/lua/lspconfig/util.lua @@ -74,6 +74,11 @@ function M.has_bins(...) return true end +M.script_path = function() + local str = debug.getinfo(2, "S").source:sub(2) + return str:match("(.*/)") +end + -- Some path utilities M.path = (function() local function exists(filename) |
