Skip to content

Commit

Permalink
fix: add autocmd to augroup
Browse files Browse the repository at this point in the history
  • Loading branch information
stevearc-stripe committed Jan 6, 2023
1 parent 7b703b4 commit 5e2f1ce
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 @@ -566,6 +566,7 @@ M.setup = function(opts)
})
vim.api.nvim_create_autocmd("BufWinEnter", {
desc = "Set/unset oil window options",
group = aug,
pattern = "*",
callback = function()
local view = require("oil.view")
Expand All @@ -577,6 +578,7 @@ M.setup = function(opts)
end,
})
vim.api.nvim_create_autocmd("BufAdd", {
desc = "Detect directory buffer and open oil file browser",
group = aug,
pattern = "*",
nested = true,
Expand Down

0 comments on commit 5e2f1ce

Please sign in to comment.