diff --git a/lua/outline/config.lua b/lua/outline/config.lua index d3d4969..2640255 100644 --- a/lua/outline/config.lua +++ b/lua/outline/config.lua @@ -234,7 +234,7 @@ function M.resolve_config() end function M.setup(options) - vim.g.symbols_outline_loaded = 1 + vim.g.outline_loaded = 1 M.o = vim.tbl_deep_extend('force', {}, M.defaults, options or {}) local guides = M.o.guides if type(guides) == 'boolean' and guides then diff --git a/lua/outline/init.lua b/lua/outline/init.lua index 78d0e67..d61cdac 100644 --- a/lua/outline/init.lua +++ b/lua/outline/init.lua @@ -527,8 +527,6 @@ function M.open_outline(opts) local found = providers.request_symbols(handler, opts) if not found then vim.notify("[outline]: No providers found for current buffer", vim.log.levels.WARN) - -- else - -- print("Using provider ".._G._symbols_outline_current_provider.name.."...") end end end @@ -591,7 +589,7 @@ end function M.show_status() if M.has_provider() then print("Current provider:") - print(' ' .. _G._symbols_outline_current_provider.name) + print(' ' .. _G._outline_current_provider.name) if M.view:is_open() then print("Outline window is open.") else @@ -612,9 +610,9 @@ end function M.has_provider() local winid = vim.fn.win_getid() if M.view:is_open() and winid == M.view.winnr then - return _G._symbols_outline_current_provider ~= nil + return _G._outline_current_provider ~= nil end - return providers.has_provider() and _G._symbols_outline_current_provider + return providers.has_provider() and _G._outline_current_provider end local function setup_commands() diff --git a/lua/outline/providers/init.lua b/lua/outline/providers/init.lua index e667b36..e3adf16 100644 --- a/lua/outline/providers/init.lua +++ b/lua/outline/providers/init.lua @@ -32,8 +32,8 @@ function M.request_symbols(on_symbols, opts) for _, value in ipairs(providers) do local provider = require(value) if provider.should_use_provider(0) then - _G._symbols_outline_current_provider = provider - _G._symbols_outline_current_provider.name = value + _G._outline_current_provider = provider + _G._outline_current_provider.name = value provider.request_symbols(on_symbols, opts) return true end