Compare commits

..

No commits in common. "135932bcf3a1cc6d9786b2c231ffee4de969efc4" and "5e301285492d3e4611accc2cde9b9850c567bf2e" have entirely different histories.

16 changed files with 188 additions and 140 deletions

View File

@ -6,11 +6,6 @@ for k, v in pairs(options.vim) do
vim.opt[k] = v vim.opt[k] = v
end end
-- set global vim options
for k, v in pairs(options.g) do
vim.g[k] = v
end
require("bootstrap") require("bootstrap")
-- apply color theme -- apply color theme

View File

@ -1,10 +1,4 @@
return { return {
-- global vim options
g = {
-- disable netrw
loaded_netrw = 1,
loaded_netrwPlugin = 1
},
vim = { vim = {
swapfile = false, -- disable swap files cuz they are garbage swapfile = false, -- disable swap files cuz they are garbage
clipboard = "unnamedplus", -- Sync with system clipboard clipboard = "unnamedplus", -- Sync with system clipboard
@ -63,8 +57,7 @@ return {
}, },
}, },
git = { git = {
-- symbols used by gitsigns icons = {
signs = {
add = "", add = "",
change = "¦", change = "¦",
delete = "", delete = "",
@ -72,11 +65,6 @@ return {
changedelete = "¦", changedelete = "¦",
untracked = "", untracked = "",
}, },
icons = {
add = "+",
change = "~",
delete = "-",
},
}, },
lazy = { lazy = {
install_missing = true, install_missing = true,

View File

@ -1,10 +1,6 @@
return { return {
{ {
"romgrk/barbar.nvim", "romgrk/barbar.nvim",
dependencies = {
'lewis6991/gitsigns.nvim', -- OPTIONAL: for git status
'nvim-tree/nvim-web-devicons', -- OPTIONAL: for file icons
},
init = function() init = function()
vim.g.barbar_auto_setup = false vim.g.barbar_auto_setup = false
end, end,
@ -33,11 +29,6 @@ return {
[vim.diagnostic.severity.HINT] = { enabled = true }, [vim.diagnostic.severity.HINT] = { enabled = true },
icon = options.lsp.icons.Hint, icon = options.lsp.icons.Hint,
}, },
gitsigns = {
added = { enabled = true, icon = options.git.icons.add },
changed = { enabled = true, icon = options.git.icons.change },
deleted = { enabled = true, icon = options.git.icons.deleted },
},
}, },
} }
end, end,

46
lua/plugins/coq.lua Normal file
View File

@ -0,0 +1,46 @@
return {
{
"ms-jpq/coq_nvim",
branch = 'coq',
build = function(_)
vim.cmd("COQdeps")
end,
config = function(_, _)
vim.cmd("COQnow -s")
end,
init = function(_)
vim.g.coq_settings = {
display = {
ghost_text = {
enabled = true,
context = { "", "" },
highlight_group = "NonText"
},
pum = {
fast_close = false,
kind_context = { " ", " " },
source_context = { "", " " },
},
icons = {
spacing = 1,
mode = "short"
},
preview = {
border = "single",
x_max_len = 25,
}
}
}
end,
dependencies = {
{
'ms-jpq/coq.artifacts',
branch = "artifacts"
},
{
"ms-jpq/coq.thirdparty",
branch = "3p"
}
}
}
}

View File

@ -1,5 +1,6 @@
return { return {
{ {
"sindrets/diffview.nvim", "sindrets/diffview.nvim",
} opts = {},
},
} }

View File

@ -1,22 +1,5 @@
return { return {
{ {
"stevearc/dressing.nvim", "stevearc/dressing.nvim",
opts = function()
local options = require('options')
return {
input = {
title_pos = "center",
border = options.ui.border,
relative = 'editor',
win_options = {
winhighlight =
'NormalFloat:Normal,FloatTitle:TelescopePromptBorder,FloatBorder:TelescopePromptBorder'
}
},
select = {
backend = { "telescope" }
}
}
end
}, },
} }

View File

@ -1,24 +0,0 @@
return {
{
'Bekaboo/dropbar.nvim',
-- optional, but required for fuzzy finder support
dependencies = {
'nvim-telescope/telescope-fzf-native.nvim'
},
opts = {
ui = {
bar = {
separator = '',
extends = '',
},
menu = {
separator = ' ',
indicator = '',
},
},
menu = {
preview = false
}
}
}
}

View File

@ -5,16 +5,16 @@ return {
local options = require("options") local options = require("options")
return { return {
signs = { signs = {
add = { text = options.git.signs.add }, add = { text = options.git.icons.add },
change = { text = options.git.signs.change }, change = { text = options.git.icons.change },
delete = { text = options.git.signs.delete }, delete = { text = options.git.icons.delete },
topdelete = { text = options.git.signs.topdelete }, topdelete = { text = options.git.icons.topdelete },
changedelete = { text = options.git.signs.changedelete }, changedelete = { text = options.git.icons.changedelete },
untracked = { text = options.git.signs.untracked }, untracked = { text = options.git.icons.untracked },
}, },
signcolumn = true, signcolumn = true,
preview_config = { preview_config = {
border = options.ui.border, border = "rounded",
}, },
} }
end, end,

25
lua/plugins/lightbulb.lua Normal file
View File

@ -0,0 +1,25 @@
return {
{
"kosayoda/nvim-lightbulb",
opts = {
autocmd = { enabled = true },
sign = {
enabled = false,
},
float = {
enabled = true,
-- Text to show in the floating window.
text = "💡",
-- Highlight group to highlight the floating window.
hl = "LightBulbFloatWin",
-- Window options.
-- See |vim.lsp.util.open_floating_preview| and |nvim_open_win|.
-- Note that some options may be overridden by |open_floating_preview|.
win_opts = {
focusable = true,
border = "none",
},
},
},
},
}

View File

@ -31,17 +31,22 @@ return {
require("mason").setup() require("mason").setup()
local coq = require('coq')
local handlers = { local handlers = {
-- The first entry (without a key) will be the default handler -- The first entry (without a key) will be the default handler
-- and will be called for each installed server that doesn't have -- and will be called for each installed server that doesn't have
-- a dedicated handler. -- a dedicated handler.
function(server_name) -- default handler (optional) function(server_name) -- default handler (optional)
require("lspconfig")[server_name].setup({ require("lspconfig")[server_name].setup(coq.lsp_ensure_capabilities({
on_attach = function(client, bufnr) on_attach = function(client, bufnr)
-- setup lsp-format -- setup lsp-format
require("lsp-format").on_attach(client, bufnr) require("lsp-format").on_attach(client, bufnr)
-- setup navic
if client.server_capabilities["documentSymbolProvider"] then
require("nvim-navic").attach(client, bufnr)
end end
}) end
}))
end, end,
} }
@ -60,13 +65,5 @@ return {
}, },
{ {
'lukas-reineke/lsp-format.nvim', 'lukas-reineke/lsp-format.nvim',
},
{
"jinzhongjia/LspUI.nvim",
branch = "main",
config = function()
require("LspUI").setup({
})
end
} }
} }

View File

@ -31,6 +31,18 @@ return {
}, },
}, },
lualine_b = { lualine_b = {
{
"filename",
color = "lualine_b_terminal",
symbols = {
modified = "", -- Text to show when the file is modified.
readonly = "", -- Text to show when the file is non-modifiable or readonly.
unnamed = "", -- Text to show for unnamed buffers.
newfile = "[New]", -- Text to show for newly created file before first write
},
},
},
lualine_c = {
{ {
function() function()
return '' return ''
@ -63,18 +75,6 @@ return {
vim.cmd("Mason") vim.cmd("Mason")
end, 100) end, 100)
end end
}
},
lualine_c = {
{
"filename",
path = 4,
symbols = {
modified = "", -- Text to show when the file is modified.
readonly = "", -- Text to show when the file is non-modifiable or readonly.
unnamed = "", -- Text to show for unnamed buffers.
newfile = "[New]", -- Text to show for newly created file before first write
},
}, },
{ {
"branch", "branch",

View File

@ -36,5 +36,5 @@ return {
line_up = "<C-S-Up>", line_up = "<C-S-Up>",
}, },
}, },
} },
} }

61
lua/plugins/navic.lua Normal file
View File

@ -0,0 +1,61 @@
return {
{
"SmiteshP/nvim-navic",
dependencies = {
"neovim/nvim-lspconfig",
},
opts = {
depth_limit_indicator = "...",
depth_limit = 8,
click = true,
},
},
{
"utilyre/barbecue.nvim",
name = "barbecue",
version = "*",
dependencies = {
"SmiteshP/nvim-navic",
"nvim-tree/nvim-web-devicons",
},
opts = {
attach_navic = false,
symbols = {
---Modification indicator.
modified = "",
---Truncation indicator.
ellipsis = "...",
---Entry separator.
separator = "",
},
kinds = {
File = "󰈙",
Module = "",
Namespace = "󰌗",
Package = "",
Class = "󰌗",
Method = "󰆧",
Property = "",
Field = "",
Constructor = "",
Enum = "󰕘",
Interface = "󰕘",
Function = "󰊕",
Variable = "󰆧",
Constant = "󰏿",
String = "󰀬",
Number = "󰎠",
Boolean = "",
Array = "󰅪",
Object = "󰅩",
Key = "󰌋",
Null = "󰟢",
EnumMember = "",
Struct = "󰌗",
Event = "",
Operator = "󰆕",
TypeParameter = "󰊄",
},
},
},
}

View File

@ -1,11 +0,0 @@
return {
{
"lewis6991/satellite.nvim",
opts = {
},
config = function(opts, _)
require('satellite').setup(opts)
end
}
}

View File

@ -1,11 +1,7 @@
return { return {
{ {
"luukvbaal/statuscol.nvim", "luukvbaal/statuscol.nvim",
lazy = true, priority = 1000,
event = {
"BufEnter",
"LspAttach"
},
config = function() config = function()
local builtin = require("statuscol.builtin") local builtin = require("statuscol.builtin")
require("statuscol").setup({ require("statuscol").setup({
@ -18,30 +14,31 @@ return {
"NvimTree", "NvimTree",
}, },
segments = { segments = {
-- folds
{
text = { builtin.foldfunc },
click = "v:lua.ScFa",
},
-- diagnostic signs -- diagnostic signs
{ {
sign = { sign = {
namespace = { "Diagnostic" }, name = { "Diagnostic" },
colwidth = 2, colwidth = 2,
maxwidth = 1,
}, },
auto = true, auto = true,
click = "v:lua.ScSa", click = "v:lua.ScSa",
}, },
-- line numbers -- line numbers
{ {
text = { builtin.lnumfunc }, text = { builtin.lnumfunc, " " },
click = "v:lua.ScLa", click = "v:lua.ScLa",
}, },
-- folds
{
text = { builtin.foldfunc },
click = "v:lua.ScFa",
},
-- git signs -- git signs
{ {
sign = { namespace = { "gitsigns" }, maxwidth = 1, }, sign = { namespace = { "gitsigns" } },
click = "v:lua.ScSa", click = "v:lua.ScSa",
} },
}, },
}) })
end, end,

View File

@ -9,7 +9,6 @@ return {
border = "single", border = "single",
winblend = 0 winblend = 0
}, },
persist_mode = true,
start_in_insert = true, start_in_insert = true,
} }
} }