Skip to content

Commit

Permalink
fix: add WinLeave autocmd to augroup
Browse files Browse the repository at this point in the history
  • Loading branch information
stevearc committed Jan 7, 2023
1 parent c6a2e3e commit 6a227e9
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lua/oil/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,8 @@ M.open_float = function(dir)
})
local winleave_autocmd
winleave_autocmd = vim.api.nvim_create_autocmd("WinLeave", {
desc = "Close floating oil window",
group = "Oil",
callback = vim.schedule_wrap(function()
if util.is_floating_win() then
return
Expand Down

0 comments on commit 6a227e9

Please sign in to comment.