added toggleterm

This commit is contained in:
Sven Vogel 2024-05-21 23:32:07 +02:00
parent a32e59eca1
commit 5e30128549
2 changed files with 66 additions and 19 deletions

View File

@ -43,6 +43,39 @@ return {
},
},
lualine_c = {
{
function()
return ''
end,
padding = 0,
on_click = function()
vim.defer_fn(function()
vim.cmd("ToggleTerm direction=horizontal")
end, 100)
end
},
{
function()
return ' 󰒲 '
end,
padding = 0,
on_click = function()
vim.defer_fn(function()
vim.cmd("Lazy")
end, 100)
end
},
{
function()
return ''
end,
padding = 0,
on_click = function()
vim.defer_fn(function()
vim.cmd("Mason")
end, 100)
end
},
{
"branch",
icon = "󰊤",
@ -65,6 +98,24 @@ return {
end, 100)
end,
},
{
"diagnostics",
symbols = {
error = options.lsp.icons.Error,
warn = options.lsp.icons.Warn,
info = options.lsp.icons.Info,
hint = options.lsp.icons.Hint,
},
sources = {
"nvim_diagnostic",
},
update_in_insert = true,
on_click = function()
vim.defer_fn(function()
vim.cmd("TroubleToggle")
end, 100)
end,
}
},
lualine_x = {
{
@ -79,25 +130,6 @@ return {
end,
color = "lualine_c_inactive",
},
{
"diagnostics",
symbols = {
error = options.lsp.icons.Error,
warn = options.lsp.icons.Warn,
info = options.lsp.icons.Info,
hint = options.lsp.icons.Hint,
},
sources = {
"nvim_diagnostic",
},
always_visible = true,
update_in_insert = true,
on_click = function()
vim.defer_fn(function()
vim.cmd("TroubleToggle")
end, 100)
end,
},
{
"filetype",
colored = true,

15
lua/plugins/term.lua Normal file
View File

@ -0,0 +1,15 @@
return {
{
"akinsho/toggleterm.nvim",
version = "*",
opts = {
hide_numbers = true,
shade_terminals = true,
float_opts = {
border = "single",
winblend = 0
},
start_in_insert = true,
}
}
}