feat: pick theme with telescope
This commit is contained in:
@@ -0,0 +1 @@
|
||||
vim.cmd("colorscheme github_dark")
|
||||
+31
-11
@@ -12,13 +12,15 @@ return {
|
||||
{
|
||||
"hrsh7th/nvim-cmp",
|
||||
config = function()
|
||||
local luasnip = require("luasnip")
|
||||
local cmp = require("cmp")
|
||||
|
||||
require("luasnip.loaders.from_vscode").lazy_load()
|
||||
|
||||
cmp.setup({
|
||||
snippet = {
|
||||
expand = function(args)
|
||||
require("luasnip").lsp_expand(args.body)
|
||||
luasnip.lsp_expand(args.body)
|
||||
end,
|
||||
},
|
||||
window = {
|
||||
@@ -26,21 +28,39 @@ return {
|
||||
documentation = cmp.config.window.bordered(),
|
||||
},
|
||||
mapping = cmp.mapping.preset.insert({
|
||||
["<C-b>"] = cmp.mapping.scroll_docs(-4),
|
||||
["<C-f>"] = cmp.mapping.scroll_docs(4),
|
||||
["<C-u>"] = cmp.mapping.scroll_docs(-4),
|
||||
["<C-d>"] = cmp.mapping.scroll_docs(4),
|
||||
["<C-Space>"] = cmp.mapping.complete(),
|
||||
["<C-e>"] = cmp.mapping.abort(),
|
||||
["<CR>"] = cmp.mapping.confirm({ select = true }),
|
||||
["<CR>"] = cmp.mapping.confirm({
|
||||
behavior = cmp.ConfirmBehavior.Replace,
|
||||
select = true,
|
||||
}),
|
||||
["<Tab>"] = cmp.mapping(function(fallback)
|
||||
if cmp.visible() then
|
||||
cmp.select_next_item()
|
||||
elseif luasnip.expand_or_jumpable() then
|
||||
luasnip.expand_or_jump()
|
||||
else
|
||||
fallback()
|
||||
end
|
||||
end, { "i", "s" }),
|
||||
["<S-Tab>"] = cmp.mapping(function(fallback)
|
||||
if cmp.visible() then
|
||||
cmp.select_prev_item()
|
||||
elseif luasnip.jumpable(-1) then
|
||||
luasnip.jump(-1)
|
||||
else
|
||||
fallback()
|
||||
end
|
||||
end, { "i", "s" }),
|
||||
}),
|
||||
sources = cmp.config.sources(
|
||||
{
|
||||
sources = cmp.config.sources({
|
||||
{ name = "nvim_lsp" },
|
||||
{ name = "luasnip" },
|
||||
},
|
||||
{
|
||||
}, {
|
||||
{ name = "buffer" },
|
||||
}),
|
||||
})
|
||||
end
|
||||
}
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
@@ -1,7 +0,0 @@
|
||||
return {
|
||||
'projekt0n/github-nvim-theme',
|
||||
name = 'github-theme',
|
||||
config = function()
|
||||
vim.cmd('colorscheme github_dark_dimmed')
|
||||
end
|
||||
}
|
||||
+11
-6
@@ -27,12 +27,12 @@ return {
|
||||
command = "EslintFixAll",
|
||||
})
|
||||
end,
|
||||
on_new_config = function (config, new_root_dir)
|
||||
config.settings.workspaceFolder = {
|
||||
uri = vim.uri_from_fname(new_root_dir),
|
||||
name = vim.fn.fnamemodify(new_root_dir, ':t'),
|
||||
}
|
||||
end
|
||||
on_new_config = function(config, new_root_dir)
|
||||
config.settings.workspaceFolder = {
|
||||
uri = vim.uri_from_fname(new_root_dir),
|
||||
name = vim.fn.fnamemodify(new_root_dir, ":t"),
|
||||
}
|
||||
end,
|
||||
})
|
||||
|
||||
lspconfig.omnisharp.setup({
|
||||
@@ -61,6 +61,7 @@ return {
|
||||
})
|
||||
|
||||
lspconfig.html.setup({
|
||||
filetypes = { "html", "ejs" },
|
||||
capabilities = capabilities,
|
||||
})
|
||||
|
||||
@@ -81,12 +82,14 @@ return {
|
||||
omnisharp.lsp_definition,
|
||||
{ desc = "Go to definition", buffer = ev.buf }
|
||||
)
|
||||
|
||||
vim.keymap.set(
|
||||
"n",
|
||||
"gi",
|
||||
omnisharp.lsp_implementation,
|
||||
{ desc = "Go to implementation", buffer = ev.buf }
|
||||
)
|
||||
|
||||
vim.keymap.set(
|
||||
"n",
|
||||
"<leader>D",
|
||||
@@ -100,12 +103,14 @@ return {
|
||||
vim.lsp.buf.definition,
|
||||
{ desc = "Go to definition", buffer = ev.buf }
|
||||
)
|
||||
|
||||
vim.keymap.set(
|
||||
"n",
|
||||
"gD",
|
||||
vim.lsp.buf.declaration,
|
||||
{ desc = "Go to declaration", buffer = ev.buf }
|
||||
)
|
||||
|
||||
vim.keymap.set(
|
||||
"n",
|
||||
"gi",
|
||||
|
||||
+17
-11
@@ -1,13 +1,19 @@
|
||||
return {
|
||||
"nvim-neo-tree/neo-tree.nvim",
|
||||
branch = "v3.x",
|
||||
dependencies = {
|
||||
"nvim-lua/plenary.nvim",
|
||||
"nvim-tree/nvim-web-devicons",
|
||||
"MunifTanjim/nui.nvim",
|
||||
},
|
||||
config = function()
|
||||
vim.keymap.set('n', '<C-b>', ':Neotree filesystem reveal right<CR>', { desc = 'Neotree show explorer' })
|
||||
end
|
||||
"nvim-neo-tree/neo-tree.nvim",
|
||||
branch = "v3.x",
|
||||
dependencies = {
|
||||
"nvim-lua/plenary.nvim",
|
||||
"nvim-tree/nvim-web-devicons",
|
||||
"MunifTanjim/nui.nvim",
|
||||
},
|
||||
config = function()
|
||||
require("neo-tree").setup({
|
||||
filesystem = {
|
||||
filtered_items = {
|
||||
visible = true,
|
||||
}
|
||||
}
|
||||
})
|
||||
vim.keymap.set("n", "<C-b>", ":Neotree filesystem reveal right<CR>", { desc = "Neotree show explorer" })
|
||||
end,
|
||||
}
|
||||
|
||||
|
||||
@@ -10,7 +10,6 @@ return {
|
||||
null_ls.builtins.formatting.black,
|
||||
null_ls.builtins.formatting.isort,
|
||||
null_ls.builtins.diagnostics.pylint,
|
||||
null_ls.builtins.completion.spell,
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
@@ -26,5 +26,11 @@ return {
|
||||
|
||||
require("telescope").load_extension("ui-select")
|
||||
end
|
||||
},
|
||||
{
|
||||
'andrew-george/telescope-themes',
|
||||
config = function()
|
||||
require('telescope').load_extension('themes')
|
||||
end
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
return {
|
||||
{
|
||||
"projekt0n/github-nvim-theme",
|
||||
name = "github-theme",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
config = function()
|
||||
require("github-theme").setup()
|
||||
end
|
||||
},
|
||||
{
|
||||
"catppuccin/nvim",
|
||||
name = "catppuccin",
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
config = function()
|
||||
require("catppuccin").setup()
|
||||
end
|
||||
},
|
||||
}
|
||||
@@ -1,13 +1,14 @@
|
||||
return {
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
return {
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
build = ":TSUpdate",
|
||||
config = function()
|
||||
local config = require("nvim-treesitter.configs")
|
||||
|
||||
|
||||
config.setup({
|
||||
auto_install = true,
|
||||
indent = { enabled = true },
|
||||
highlight = { enabled = true }
|
||||
highlight = { enabled = true },
|
||||
})
|
||||
end
|
||||
|
||||
end,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user