setting up lualine
This commit is contained in:
@@ -516,6 +516,9 @@ require('lazy').setup({
|
|||||||
-- For example, in C this would take you to the header.
|
-- For example, in C this would take you to the header.
|
||||||
map('gD', vim.lsp.buf.declaration, '[G]oto [D]eclaration')
|
map('gD', vim.lsp.buf.declaration, '[G]oto [D]eclaration')
|
||||||
|
|
||||||
|
map('<leader>lg', vim.diagnostic.open_float, 'Open diagnostics')
|
||||||
|
map('<leader>lf', vim.lsp.buf.format, '[L]sp [F]ormat')
|
||||||
|
|
||||||
-- The following two autocommands are used to highlight references of the
|
-- The following two autocommands are used to highlight references of the
|
||||||
-- word under your cursor when your cursor rests there for a little while.
|
-- word under your cursor when your cursor rests there for a little while.
|
||||||
-- See `:help CursorHold` for information about when this is executed
|
-- See `:help CursorHold` for information about when this is executed
|
||||||
@@ -553,6 +556,11 @@ require('lazy').setup({
|
|||||||
-- - settings (table): Override the default settings passed when initializing the server.
|
-- - settings (table): Override the default settings passed when initializing the server.
|
||||||
-- For example, to see the options for `lua_ls`, you could go to: https://luals.github.io/wiki/settings/
|
-- For example, to see the options for `lua_ls`, you could go to: https://luals.github.io/wiki/settings/
|
||||||
local servers = {
|
local servers = {
|
||||||
|
-- FIXME:
|
||||||
|
-- qmlls = {
|
||||||
|
-- cmd = { '/home/talksik/Qt/6.6.1/gcc_64/bin/qmlls' },
|
||||||
|
-- filetypes = { 'qml' },
|
||||||
|
-- },
|
||||||
clangd = {
|
clangd = {
|
||||||
cmd = {
|
cmd = {
|
||||||
'/home/talksik/Qt/Tools/QtCreator/libexec/qtcreator/clang/bin/clangd',
|
'/home/talksik/Qt/Tools/QtCreator/libexec/qtcreator/clang/bin/clangd',
|
||||||
@@ -789,21 +797,6 @@ require('lazy').setup({
|
|||||||
-- - sr)' - [S]urround [R]eplace [)] [']
|
-- - sr)' - [S]urround [R]eplace [)] [']
|
||||||
require('mini.surround').setup()
|
require('mini.surround').setup()
|
||||||
|
|
||||||
-- Simple and easy statusline.
|
|
||||||
-- You could remove this setup call if you don't like it,
|
|
||||||
-- and try some other statusline plugin
|
|
||||||
local statusline = require 'mini.statusline'
|
|
||||||
-- set use_icons to true if you have a Nerd Font
|
|
||||||
statusline.setup { use_icons = vim.g.have_nerd_font }
|
|
||||||
|
|
||||||
-- You can configure sections in the statusline by overriding their
|
|
||||||
-- default behavior. For example, here we set the section for
|
|
||||||
-- cursor location to LINE:COLUMN
|
|
||||||
---@diagnostic disable-next-line: duplicate-set-field
|
|
||||||
statusline.section_location = function()
|
|
||||||
return '%2l:%-2v'
|
|
||||||
end
|
|
||||||
|
|
||||||
-- ... and there is more!
|
-- ... and there is more!
|
||||||
-- Check out: https://github.com/echasnovski/mini.nvim
|
-- Check out: https://github.com/echasnovski/mini.nvim
|
||||||
end,
|
end,
|
||||||
|
|||||||
@@ -37,4 +37,51 @@ return {
|
|||||||
vim.api.nvim_set_keymap('n', 'zz', '<cmd>ZenMode<CR>', { noremap = true, silent = true })
|
vim.api.nvim_set_keymap('n', 'zz', '<cmd>ZenMode<CR>', { noremap = true, silent = true })
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
'nvim-lualine/lualine.nvim',
|
||||||
|
config = function()
|
||||||
|
require('lualine').setup {
|
||||||
|
options = {
|
||||||
|
icons_enabled = true,
|
||||||
|
theme = 'solarized',
|
||||||
|
},
|
||||||
|
sections = {
|
||||||
|
lualine_a = {
|
||||||
|
{
|
||||||
|
'mode',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
lualine_b = {
|
||||||
|
{
|
||||||
|
'filename',
|
||||||
|
path = 4,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
lualine_c = {
|
||||||
|
{
|
||||||
|
'diff',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
'diagnostics',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
-- lualine_x = {
|
||||||
|
-- },
|
||||||
|
-- lualine_y = {
|
||||||
|
-- },
|
||||||
|
lualine_z = {
|
||||||
|
{
|
||||||
|
'datetime',
|
||||||
|
-- options: default, us, uk, iso, or your own format string ("%H:%M", etc..)
|
||||||
|
style = '%H:%M:%S',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
'filesize',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
end,
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user