fix lualine colors, add mapping for lsp snippets, add neodev
This commit is contained in:
@@ -1,8 +1,16 @@
|
||||
return {
|
||||
"ellisonleao/gruvbox.nvim",
|
||||
priority = 1000,
|
||||
config = function()
|
||||
require("gruvbox").setup({})
|
||||
vim.cmd("colorscheme gruvbox")
|
||||
end
|
||||
{
|
||||
"ellisonleao/gruvbox.nvim",
|
||||
priority = 1000,
|
||||
config = function()
|
||||
require("gruvbox").setup({})
|
||||
vim.cmd("colorscheme gruvbox")
|
||||
end
|
||||
},
|
||||
{
|
||||
"norcalli/nvim-colorizer.lua",
|
||||
config = function ()
|
||||
require('colorizer').setup({ '*' })
|
||||
end
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,43 +0,0 @@
|
||||
return {
|
||||
{
|
||||
"lewis6991/gitsigns.nvim",
|
||||
config = function ()
|
||||
require('gitsigns').setup()
|
||||
end
|
||||
},
|
||||
{
|
||||
"rebelot/heirline.nvim",
|
||||
version = "1.0.*",
|
||||
dependencies = { "Zeioth/heirline-components.nvim" },
|
||||
opts = function()
|
||||
local lib = require("heirline-components.all")
|
||||
return {
|
||||
|
||||
statusline = { -- UI statusbar
|
||||
hl = { fg = "fg", bg = "bg" },
|
||||
lib.component.mode(),
|
||||
lib.component.git_branch(),
|
||||
lib.component.file_info(),
|
||||
lib.component.git_diff(),
|
||||
lib.component.diagnostics(),
|
||||
lib.component.fill(),
|
||||
lib.component.cmd_info(),
|
||||
lib.component.fill(),
|
||||
lib.component.lsp(),
|
||||
lib.component.compiler_state(),
|
||||
lib.component.virtual_env(),
|
||||
lib.component.nav(),
|
||||
lib.component.mode { surround = { separator = "right" } },
|
||||
},
|
||||
}
|
||||
end,
|
||||
config = function(_, opts)
|
||||
local heirline = require "heirline"
|
||||
local heirline_components = require "heirline-components.all"
|
||||
|
||||
heirline_components.init.subscribe_to_events()
|
||||
heirline.load_colors(heirline_components.hl.get_colors())
|
||||
heirline.setup(opts)
|
||||
end
|
||||
}
|
||||
}
|
||||
@@ -15,6 +15,7 @@ return {
|
||||
|
||||
config = function()
|
||||
local cmp = require('cmp')
|
||||
local luasnip = require("luasnip")
|
||||
|
||||
require("fidget").setup({})
|
||||
require('mason').setup({})
|
||||
@@ -37,7 +38,39 @@ return {
|
||||
},
|
||||
mapping = cmp.mapping.preset.insert({
|
||||
-- `Enter` key to confirm completion
|
||||
['<CR>'] = cmp.mapping.confirm({ select = false }),
|
||||
['<CR>'] = cmp.mapping(function(fallback)
|
||||
if cmp.visible() then
|
||||
if luasnip.expandable() then
|
||||
luasnip.expand()
|
||||
else
|
||||
cmp.confirm({
|
||||
select = true,
|
||||
})
|
||||
end
|
||||
else
|
||||
fallback()
|
||||
end
|
||||
end),
|
||||
|
||||
["<Tab>"] = cmp.mapping(function(fallback)
|
||||
if cmp.visible() then
|
||||
cmp.select_next_item()
|
||||
elseif luasnip.locally_jumpable(1) then
|
||||
luasnip.jump(1)
|
||||
else
|
||||
fallback()
|
||||
end
|
||||
end, { "i", "s" }),
|
||||
|
||||
["<S-Tab>"] = cmp.mapping(function(fallback)
|
||||
if cmp.visible() then
|
||||
cmp.select_prev_item()
|
||||
elseif luasnip.locally_jumpable(-1) then
|
||||
luasnip.jump(-1)
|
||||
else
|
||||
fallback()
|
||||
end
|
||||
end, { "i", "s" }),
|
||||
|
||||
-- Ctrl+Space to trigger completion menu
|
||||
['<C-Space>'] = cmp.mapping.complete(),
|
||||
@@ -51,6 +84,7 @@ return {
|
||||
require('luasnip').lsp_expand(args.body)
|
||||
end,
|
||||
},
|
||||
|
||||
})
|
||||
end
|
||||
}
|
||||
|
||||
55
lua/crentist/lazy/lualine.lua
Normal file
55
lua/crentist/lazy/lualine.lua
Normal file
@@ -0,0 +1,55 @@
|
||||
return {
|
||||
'nvim-lualine/lualine.nvim',
|
||||
dependencies = { 'nvim-tree/nvim-web-devicons' },
|
||||
config = function()
|
||||
local colors = {
|
||||
black = '#282828',
|
||||
white = '#ebdbb2',
|
||||
red = '#fb4934',
|
||||
green = '#b8bb26',
|
||||
blue = '#458588',
|
||||
yellow = '#fabd2f',
|
||||
magenta = '#d3869b',
|
||||
darkgray = '#3c3836',
|
||||
lightgray = '#504945',
|
||||
inactivegray = '#7c6f64',
|
||||
}
|
||||
require('lualine').setup({
|
||||
options = {
|
||||
theme = {
|
||||
normal = {
|
||||
a = { bg = colors.yellow, fg = colors.black, gui = 'bold' },
|
||||
b = { bg = colors.lightgray, fg = colors.white },
|
||||
c = { bg = colors.darkgray, fg = colors.white },
|
||||
},
|
||||
insert = {
|
||||
a = { bg = colors.blue, fg = colors.black, gui = 'bold' },
|
||||
b = { bg = colors.lightgray, fg = colors.white },
|
||||
c = { bg = colors.lightgray, fg = colors.white },
|
||||
},
|
||||
visual = {
|
||||
a = { bg = colors.magenta, fg = colors.black, gui = 'bold' },
|
||||
b = { bg = colors.lightgray, fg = colors.white },
|
||||
c = { bg = colors.inactivegray, fg = colors.black },
|
||||
},
|
||||
replace = {
|
||||
a = { bg = colors.red, fg = colors.black, gui = 'bold' },
|
||||
b = { bg = colors.lightgray, fg = colors.white },
|
||||
c = { bg = colors.black, fg = colors.white },
|
||||
},
|
||||
command = {
|
||||
a = { bg = colors.green, fg = colors.black, gui = 'bold' },
|
||||
b = { bg = colors.lightgray, fg = colors.white },
|
||||
c = { bg = colors.inactivegray, fg = colors.black },
|
||||
},
|
||||
inactive = {
|
||||
a = { bg = colors.darkgray, fg = colors.magenta, gui = 'bold' },
|
||||
b = { bg = colors.darkgray, fg = colors.magenta },
|
||||
c = { bg = colors.darkgray, fg = colors.magenta },
|
||||
},
|
||||
}
|
||||
},
|
||||
|
||||
})
|
||||
end
|
||||
}
|
||||
3
lua/crentist/lazy/neodev.lua
Normal file
3
lua/crentist/lazy/neodev.lua
Normal file
@@ -0,0 +1,3 @@
|
||||
return {
|
||||
{ "folke/neodev.nvim", opts = {} }
|
||||
}
|
||||
Reference in New Issue
Block a user