diff --git a/lua/codemp/command.lua b/lua/codemp/command.lua index d8625d3..aa90596 100644 --- a/lua/codemp/command.lua +++ b/lua/codemp/command.lua @@ -87,6 +87,7 @@ local connected_actions = { print(" xx disconnecting client " .. CODEMP.client.id) CODEMP.client = nil -- should drop and thus close everything collectgarbage("collect") -- make sure we drop + require('codemp.window').update() end, } diff --git a/lua/codemp/init.lua b/lua/codemp/init.lua index 964fd4f..a29d95f 100644 --- a/lua/codemp/init.lua +++ b/lua/codemp/init.lua @@ -46,6 +46,7 @@ if CODEMP == nil then CODEMP.client = nil -- drop reference so it gets garbage collected end CODEMP.rt:stop() + require('codemp.window').update() end } ) diff --git a/lua/codemp/neo-tree/commands.lua b/lua/codemp/neo-tree/commands.lua index 021f9d9..bb6708c 100644 --- a/lua/codemp/neo-tree/commands.lua +++ b/lua/codemp/neo-tree/commands.lua @@ -118,6 +118,7 @@ M.delete = function(state, path, extra) if not choice or not vim.startswith(string.lower(choice), "y") then return end if CODEMP.workspace ~= nil then ws_manager.leave() end CODEMP.client = nil + manager.refresh("codemp") collectgarbage("collect") -- to make sure we drop the reference and disconnect end) elseif selected.type == "root" and vim.startswith(selected.name, "#") then