Skip to content

Commit

Permalink
Fix dashboard status autocmd
Browse files Browse the repository at this point in the history
Signed-off-by: Micah Halter <micah@balena.io>
  • Loading branch information
mehalter committed Apr 17, 2022
1 parent 426395d commit a033dc8
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
1 change: 0 additions & 1 deletion lua/configs/dashboard.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ function M.config()

local plugins_count = fn.len(vim.fn.globpath(fn.stdpath "data" .. "/site/pack/packer/start", "*", 0, 1))

g.dashboard_disable_statusline = 1
g.dashboard_default_executive = "telescope"
g.dashboard_custom_header = {
" ",
Expand Down
12 changes: 12 additions & 0 deletions lua/core/autocmds.lua
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,18 @@ if utils.is_available "dashboard-nvim" and utils.is_available "bufferline.nvim"
pattern = "<buffer>",
command = "set showtabline=2",
})
cmd("FileType", {
desc = "Disable statusline for dashboard",
group = "dashboard_settings",
pattern = "dashboard",
command = "set laststatus=0",
})
cmd("BufWinLeave", {
desc = "Reenable statusline when leaving dashboard",
group = "dashboard_settings",
pattern = "<buffer>",
command = "set laststatus=3",
})
cmd("BufEnter", {
desc = "No cursorline on dashboard",
group = "dashboard_settings",
Expand Down

0 comments on commit a033dc8

Please sign in to comment.