change colorscheme to zenwritten
This commit is contained in:
parent
67d9542ca5
commit
7f95d6770f
4 changed files with 321 additions and 306 deletions
|
@ -1,204 +1,204 @@
|
|||
return {
|
||||
{ "hrsh7th/cmp-nvim-lsp" },
|
||||
{ "hrsh7th/cmp-cmdline" },
|
||||
{ "hrsh7th/cmp-path" },
|
||||
{ "hrsh7th/cmp-buffer" },
|
||||
{
|
||||
"ray-x/lsp_signature.nvim",
|
||||
event = "InsertEnter",
|
||||
opts = {},
|
||||
},
|
||||
{
|
||||
"folke/lazydev.nvim",
|
||||
ft = "lua", -- only load on lua files
|
||||
opts = {
|
||||
library = {
|
||||
-- See the configuration section for more details
|
||||
-- Load luvit types when the `vim.uv` word is found
|
||||
{ path = "${3rd}/luv/library", words = { "vim%.uv" } },
|
||||
},
|
||||
{ "hrsh7th/cmp-nvim-lsp" },
|
||||
{ "hrsh7th/cmp-cmdline" },
|
||||
{ "hrsh7th/cmp-path" },
|
||||
{ "hrsh7th/cmp-buffer" },
|
||||
{
|
||||
"ray-x/lsp_signature.nvim",
|
||||
event = "InsertEnter",
|
||||
opts = {},
|
||||
},
|
||||
},
|
||||
{
|
||||
"williamboman/mason-lspconfig.nvim",
|
||||
opts = {
|
||||
ensure_installed = { "lua_ls", "rust_analyzer", "clangd", "zls" },
|
||||
handlers = {
|
||||
function(server_name)
|
||||
vim.opt.signcolumn = "yes"
|
||||
local navic = require "nvim-navic"
|
||||
|
||||
local on_attach = function(client, bufnr)
|
||||
require("lsp_signature").on_attach({}, bufnr)
|
||||
if client.server_capabilities.documentSymbolProvider then
|
||||
navic.attach(client, bufnr)
|
||||
end
|
||||
end
|
||||
|
||||
local capabilities = require("cmp_nvim_lsp").default_capabilities()
|
||||
|
||||
require("lspconfig")[server_name].setup {
|
||||
on_attach = on_attach,
|
||||
capabilities = capabilities,
|
||||
}
|
||||
end,
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
"onsails/lspkind.nvim",
|
||||
config = function()
|
||||
require("lspkind").init { preset = "codicons" }
|
||||
end,
|
||||
},
|
||||
{
|
||||
"hrsh7th/nvim-cmp",
|
||||
config = function()
|
||||
local cmp = require "cmp"
|
||||
local lspkind = require "lspkind"
|
||||
|
||||
cmp.setup {
|
||||
formatting = {
|
||||
format = lspkind.cmp_format {
|
||||
mode = "symbol", -- show only symbol annotations
|
||||
maxwidth = {
|
||||
menu = 50, -- leading text (labelDetails)
|
||||
abbr = 50, -- actual suggestion item
|
||||
{
|
||||
"folke/lazydev.nvim",
|
||||
ft = "lua", -- only load on lua files
|
||||
opts = {
|
||||
library = {
|
||||
-- See the configuration section for more details
|
||||
-- Load luvit types when the `vim.uv` word is found
|
||||
{ path = "${3rd}/luv/library", words = { "vim%.uv" } },
|
||||
},
|
||||
ellipsis_char = "...", -- when popup menu exceed maxwidth, the truncated part would show ellipsis_char instead (must define maxwidth first)
|
||||
show_labelDetails = true, -- show labelDetails in menu. Disabled by default
|
||||
|
||||
before = function(entry, vim_item)
|
||||
local highlights_info = require("colorful-menu").cmp_highlights(entry)
|
||||
|
||||
-- highlight_info is nil means we are missing the ts parser, it's
|
||||
-- better to fallback to use default `vim_item.abbr`. What this plugin
|
||||
-- offers is two fields: `vim_item.abbr_hl_group` and `vim_item.abbr`.
|
||||
if highlights_info ~= nil then
|
||||
vim_item.abbr_hl_group = highlights_info.highlights
|
||||
vim_item.abbr = highlights_info.text
|
||||
end
|
||||
|
||||
return vim_item
|
||||
end,
|
||||
},
|
||||
},
|
||||
sources = {
|
||||
{ name = "nvim_lsp" },
|
||||
{
|
||||
name = "lazydev",
|
||||
group_index = 0, -- set group index to 0 to skip loading LuaLS completions
|
||||
},
|
||||
},
|
||||
snippet = {
|
||||
expand = function(args)
|
||||
vim.snippet.expand(args.body)
|
||||
end,
|
||||
},
|
||||
mapping = cmp.mapping.preset.insert {
|
||||
["<C-b>"] = cmp.mapping.scroll_docs(-4),
|
||||
["<C-f>"] = cmp.mapping.scroll_docs(4),
|
||||
["<C-Space>"] = cmp.mapping.complete(),
|
||||
["<C-e>"] = cmp.mapping.abort(),
|
||||
["<CR>"] = cmp.mapping.confirm { select = true }, -- Accept currently selected item. Set `select` to `false` to only confirm explicitly selected items.
|
||||
},
|
||||
}
|
||||
|
||||
cmp.setup.cmdline({ "/", "?" }, {
|
||||
mapping = cmp.mapping.preset.cmdline(),
|
||||
sources = {
|
||||
{ name = "buffer" },
|
||||
},
|
||||
})
|
||||
|
||||
-- Use cmdline & path source for ':' (if you enabled `native_menu`, this won't work anymore).
|
||||
cmp.setup.cmdline(":", {
|
||||
mapping = cmp.mapping.preset.cmdline(),
|
||||
sources = cmp.config.sources({
|
||||
{ name = "path" },
|
||||
}, {
|
||||
{ name = "cmdline" },
|
||||
}),
|
||||
matching = { disallow_symbol_nonprefix_matching = false },
|
||||
})
|
||||
end,
|
||||
},
|
||||
{
|
||||
"neovim/nvim-lspconfig",
|
||||
lazy = false,
|
||||
keys = {
|
||||
{
|
||||
"ca",
|
||||
vim.lsp.buf.code_action,
|
||||
desc = "LSP: [C]ode Action",
|
||||
},
|
||||
{
|
||||
"<leader>rr",
|
||||
vim.lsp.buf.rename,
|
||||
desc = "LSP rename",
|
||||
},
|
||||
{
|
||||
"<leader>lh",
|
||||
vim.lsp.buf.hover,
|
||||
desc = "[L]sp: Hover",
|
||||
},
|
||||
},
|
||||
config = function()
|
||||
vim.opt.signcolumn = "yes"
|
||||
local navic = require "nvim-navic"
|
||||
{
|
||||
"williamboman/mason-lspconfig.nvim",
|
||||
opts = {
|
||||
ensure_installed = { "lua_ls", "rust_analyzer", "clangd", "zls" },
|
||||
handlers = {
|
||||
function(server_name)
|
||||
vim.opt.signcolumn = "yes"
|
||||
local navic = require "nvim-navic"
|
||||
|
||||
local on_attach = function(client, bufnr)
|
||||
if client.server_capabilities.documentSymbolProvider then
|
||||
navic.attach(client, bufnr)
|
||||
end
|
||||
end
|
||||
local on_attach = function(client, bufnr)
|
||||
require("lsp_signature").on_attach({}, bufnr)
|
||||
if client.server_capabilities.documentSymbolProvider then
|
||||
navic.attach(client, bufnr)
|
||||
end
|
||||
end
|
||||
|
||||
vim.filetype.add {
|
||||
extension = {
|
||||
hlsl = "hlsl",
|
||||
local capabilities = require("cmp_nvim_lsp").default_capabilities()
|
||||
|
||||
require("lspconfig")[server_name].setup {
|
||||
on_attach = on_attach,
|
||||
capabilities = capabilities,
|
||||
}
|
||||
end,
|
||||
},
|
||||
},
|
||||
}
|
||||
},
|
||||
{
|
||||
"onsails/lspkind.nvim",
|
||||
config = function()
|
||||
require("lspkind").init { preset = "codicons" }
|
||||
end,
|
||||
},
|
||||
{
|
||||
"hrsh7th/nvim-cmp",
|
||||
config = function()
|
||||
local cmp = require "cmp"
|
||||
local lspkind = require "lspkind"
|
||||
|
||||
if not require("lspconfig.configs").hlsl_tools then
|
||||
require("lspconfig.configs").hlsl_tools = {
|
||||
default_config = {
|
||||
cmd = "/home/hstasonis/.config/nvim/vendor/shader-language-server",
|
||||
on_new_config = function(new_config, _)
|
||||
new_config.cmd_env.LD_LIBRARY_PATH = "/home/hstasonis/.config/nvim/vendor"
|
||||
end,
|
||||
},
|
||||
single_file_support = true,
|
||||
filetypes = { "hlsl" },
|
||||
}
|
||||
end
|
||||
cmp.setup {
|
||||
formatting = {
|
||||
format = lspkind.cmp_format {
|
||||
mode = "symbol", -- show only symbol annotations
|
||||
maxwidth = {
|
||||
menu = 50, -- leading text (labelDetails)
|
||||
abbr = 50, -- actual suggestion item
|
||||
},
|
||||
ellipsis_char = "...", -- when popup menu exceed maxwidth, the truncated part would show ellipsis_char instead (must define maxwidth first)
|
||||
show_labelDetails = true, -- show labelDetails in menu. Disabled by default
|
||||
|
||||
-- Set it up as usual
|
||||
require("lspconfig.configs").hlsl_tools.setup {
|
||||
on_attach = on_attach,
|
||||
}
|
||||
end,
|
||||
},
|
||||
{
|
||||
"williamboman/mason.nvim",
|
||||
config = function()
|
||||
require("mason").setup {}
|
||||
end,
|
||||
},
|
||||
{
|
||||
"SmiteshP/nvim-navic",
|
||||
config = function()
|
||||
vim.o.winbar = "%{%v:lua.require'nvim-navic'.get_location()%}"
|
||||
end,
|
||||
},
|
||||
{
|
||||
"j-hui/fidget.nvim",
|
||||
opts = {},
|
||||
},
|
||||
{
|
||||
"xzbdmw/colorful-menu.nvim",
|
||||
config = function()
|
||||
-- You don't need to set these options.
|
||||
require("colorful-menu").setup {}
|
||||
end,
|
||||
},
|
||||
before = function(entry, vim_item)
|
||||
local highlights_info = require("colorful-menu").cmp_highlights(entry)
|
||||
|
||||
-- highlight_info is nil means we are missing the ts parser, it's
|
||||
-- better to fallback to use default `vim_item.abbr`. What this plugin
|
||||
-- offers is two fields: `vim_item.abbr_hl_group` and `vim_item.abbr`.
|
||||
if highlights_info ~= nil then
|
||||
vim_item.abbr_hl_group = highlights_info.highlights
|
||||
vim_item.abbr = highlights_info.text
|
||||
end
|
||||
|
||||
return vim_item
|
||||
end,
|
||||
},
|
||||
},
|
||||
sources = {
|
||||
{ name = "nvim_lsp" },
|
||||
{
|
||||
name = "lazydev",
|
||||
group_index = 0, -- set group index to 0 to skip loading LuaLS completions
|
||||
},
|
||||
},
|
||||
snippet = {
|
||||
expand = function(args)
|
||||
vim.snippet.expand(args.body)
|
||||
end,
|
||||
},
|
||||
mapping = cmp.mapping.preset.insert {
|
||||
["<C-b>"] = cmp.mapping.scroll_docs(-4),
|
||||
["<C-f>"] = cmp.mapping.scroll_docs(4),
|
||||
["<C-Space>"] = cmp.mapping.complete(),
|
||||
["<C-e>"] = cmp.mapping.abort(),
|
||||
["<CR>"] = cmp.mapping.confirm { select = true }, -- Accept currently selected item. Set `select` to `false` to only confirm explicitly selected items.
|
||||
},
|
||||
}
|
||||
|
||||
cmp.setup.cmdline({ "/", "?" }, {
|
||||
mapping = cmp.mapping.preset.cmdline(),
|
||||
sources = {
|
||||
{ name = "buffer" },
|
||||
},
|
||||
})
|
||||
|
||||
-- Use cmdline & path source for ':' (if you enabled `native_menu`, this won't work anymore).
|
||||
cmp.setup.cmdline(":", {
|
||||
mapping = cmp.mapping.preset.cmdline(),
|
||||
sources = cmp.config.sources({
|
||||
{ name = "path" },
|
||||
}, {
|
||||
{ name = "cmdline" },
|
||||
}),
|
||||
matching = { disallow_symbol_nonprefix_matching = false },
|
||||
})
|
||||
end,
|
||||
},
|
||||
{
|
||||
"neovim/nvim-lspconfig",
|
||||
lazy = false,
|
||||
keys = {
|
||||
{
|
||||
"ca",
|
||||
vim.lsp.buf.code_action,
|
||||
desc = "LSP: [C]ode Action",
|
||||
},
|
||||
{
|
||||
"<leader>rr",
|
||||
vim.lsp.buf.rename,
|
||||
desc = "LSP rename",
|
||||
},
|
||||
{
|
||||
"<leader>lh",
|
||||
vim.lsp.buf.hover,
|
||||
desc = "[L]sp: Hover",
|
||||
},
|
||||
},
|
||||
config = function()
|
||||
vim.opt.signcolumn = "yes"
|
||||
local navic = require "nvim-navic"
|
||||
|
||||
local on_attach = function(client, bufnr)
|
||||
if client.server_capabilities.documentSymbolProvider then
|
||||
navic.attach(client, bufnr)
|
||||
end
|
||||
end
|
||||
|
||||
vim.filetype.add {
|
||||
extension = {
|
||||
hlsl = "hlsl",
|
||||
},
|
||||
}
|
||||
|
||||
if not require("lspconfig.configs").hlsl_tools then
|
||||
require("lspconfig.configs").hlsl_tools = {
|
||||
default_config = {
|
||||
cmd = "/home/hstasonis/.config/nvim/vendor/shader-language-server",
|
||||
on_new_config = function(new_config, _)
|
||||
new_config.cmd_env.LD_LIBRARY_PATH = "/home/hstasonis/.config/nvim/vendor"
|
||||
end,
|
||||
},
|
||||
single_file_support = true,
|
||||
filetypes = { "hlsl" },
|
||||
}
|
||||
end
|
||||
|
||||
-- Set it up as usual
|
||||
require("lspconfig.configs").hlsl_tools.setup {
|
||||
on_attach = on_attach,
|
||||
}
|
||||
end,
|
||||
},
|
||||
{
|
||||
"williamboman/mason.nvim",
|
||||
config = function()
|
||||
require("mason").setup {}
|
||||
end,
|
||||
},
|
||||
{
|
||||
"SmiteshP/nvim-navic",
|
||||
config = function()
|
||||
vim.o.winbar = "%{%v:lua.require'nvim-navic'.get_location()%}"
|
||||
end,
|
||||
},
|
||||
{
|
||||
"j-hui/fidget.nvim",
|
||||
opts = {},
|
||||
},
|
||||
{
|
||||
"xzbdmw/colorful-menu.nvim",
|
||||
config = function()
|
||||
-- You don't need to set these options.
|
||||
require("colorful-menu").setup {}
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
|
|
@ -1,95 +1,106 @@
|
|||
return {
|
||||
{
|
||||
"ramojus/mellifluous.nvim",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
enabled = true,
|
||||
config = function()
|
||||
require("mellifluous").setup {
|
||||
colorset = "alduin",
|
||||
} -- optional, see configuration section.
|
||||
{
|
||||
"ramojus/mellifluous.nvim",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
enabled = false,
|
||||
config = function()
|
||||
require("mellifluous").setup {
|
||||
--colorset = "alduin",
|
||||
colorset = "mellifluous"
|
||||
} -- optional, see configuration section.
|
||||
|
||||
vim.cmd [[ colorscheme mellifluous ]]
|
||||
end,
|
||||
},
|
||||
{
|
||||
"datsfilipe/vesper.nvim",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
enabled = false,
|
||||
config = function()
|
||||
require("vesper").setup {
|
||||
transparent = false,
|
||||
}
|
||||
|
||||
vim.cmd [[ colorscheme vesper ]]
|
||||
end,
|
||||
},
|
||||
{
|
||||
"AlexvZyl/nordic.nvim",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
enabled = false,
|
||||
config = function()
|
||||
require("nordic").load {
|
||||
bright_border = true,
|
||||
}
|
||||
end,
|
||||
},
|
||||
{
|
||||
"akinsho/bufferline.nvim",
|
||||
version = "*",
|
||||
lazy = false,
|
||||
dependencies = { "nvim-tree/nvim-web-devicons", "datsfilipe/vesper.nvim" },
|
||||
keys = {
|
||||
{
|
||||
"<leader>[",
|
||||
":BufferLineCyclePrev<CR>",
|
||||
desc = "Go back a buffer",
|
||||
},
|
||||
{
|
||||
"<leader>]",
|
||||
":BufferLineCycleNext<CR>",
|
||||
desc = "Go to the next buffer",
|
||||
},
|
||||
{
|
||||
"<leader>-",
|
||||
":BufferLineCloseLeft<CR>",
|
||||
desc = "Bufferline: Close left",
|
||||
},
|
||||
{
|
||||
"<leader>+",
|
||||
":BufferLineCloseOthers<CR>",
|
||||
desc = "Bufferline: Close others",
|
||||
},
|
||||
{
|
||||
"<leader>_",
|
||||
":BufferLineCloseRight<CR>",
|
||||
desc = "Bufferline: Close right",
|
||||
},
|
||||
{
|
||||
"<leader>=",
|
||||
":BufDel<CR>",
|
||||
desc = "Close current buffer",
|
||||
},
|
||||
vim.cmd [[ colorscheme mellifluous ]]
|
||||
end,
|
||||
},
|
||||
|
||||
opts = {
|
||||
diagnostics = "nvim_lsp",
|
||||
|
||||
diagnostics_indicator = function(count, level, diagnostics_dict, context)
|
||||
local icon = level:match "error" and " " or " "
|
||||
return " " .. icon .. count
|
||||
end,
|
||||
{
|
||||
"zenbones-theme/zenbones.nvim",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
enabled = true,
|
||||
dependencies = "rktjmp/lush.nvim",
|
||||
config = function()
|
||||
vim.cmd [[ colorscheme zenwritten ]]
|
||||
end,
|
||||
},
|
||||
{
|
||||
"datsfilipe/vesper.nvim",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
enabled = false,
|
||||
config = function()
|
||||
require("vesper").setup {
|
||||
transparent = false,
|
||||
}
|
||||
|
||||
vim.cmd [[ colorscheme vesper ]]
|
||||
end,
|
||||
},
|
||||
{
|
||||
"AlexvZyl/nordic.nvim",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
enabled = false,
|
||||
config = function()
|
||||
require("nordic").load {
|
||||
bright_border = true,
|
||||
}
|
||||
end,
|
||||
},
|
||||
{
|
||||
"akinsho/bufferline.nvim",
|
||||
version = "*",
|
||||
lazy = false,
|
||||
dependencies = { "nvim-tree/nvim-web-devicons", "datsfilipe/vesper.nvim" },
|
||||
keys = {
|
||||
{
|
||||
"<leader>[",
|
||||
":BufferLineCyclePrev<CR>",
|
||||
desc = "Go back a buffer",
|
||||
},
|
||||
{
|
||||
"<leader>]",
|
||||
":BufferLineCycleNext<CR>",
|
||||
desc = "Go to the next buffer",
|
||||
},
|
||||
{
|
||||
"<leader>-",
|
||||
":BufferLineCloseLeft<CR>",
|
||||
desc = "Bufferline: Close left",
|
||||
},
|
||||
{
|
||||
"<leader>+",
|
||||
":BufferLineCloseOthers<CR>",
|
||||
desc = "Bufferline: Close others",
|
||||
},
|
||||
{
|
||||
"<leader>_",
|
||||
":BufferLineCloseRight<CR>",
|
||||
desc = "Bufferline: Close right",
|
||||
},
|
||||
{
|
||||
"<leader>=",
|
||||
":BufDel<CR>",
|
||||
desc = "Close current buffer",
|
||||
},
|
||||
},
|
||||
|
||||
opts = {
|
||||
diagnostics = "nvim_lsp",
|
||||
|
||||
diagnostics_indicator = function(count, level, diagnostics_dict, context)
|
||||
local icon = level:match "error" and " " or " "
|
||||
return " " .. icon .. count
|
||||
end,
|
||||
},
|
||||
config = function(_, opts)
|
||||
require("bufferline").setup {
|
||||
options = opts,
|
||||
}
|
||||
end,
|
||||
},
|
||||
{
|
||||
"ojroques/nvim-bufdel",
|
||||
opts = {},
|
||||
},
|
||||
config = function(_, opts)
|
||||
require("bufferline").setup {
|
||||
options = opts,
|
||||
}
|
||||
end,
|
||||
},
|
||||
{
|
||||
"ojroques/nvim-bufdel",
|
||||
opts = {},
|
||||
},
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue