nvim: trim useless fat
This commit is contained in:
parent
2530e4298a
commit
85d91ed449
@ -10,20 +10,6 @@ lsp_zero.on_attach(function(client, bufnr)
|
|||||||
vim.diagnostic.config({virtual_text = false})
|
vim.diagnostic.config({virtual_text = false})
|
||||||
end)
|
end)
|
||||||
|
|
||||||
-- Omnisharp
|
|
||||||
|
|
||||||
-- Mason
|
|
||||||
require('mason').setup({})
|
|
||||||
require('mason-lspconfig').setup({
|
|
||||||
handlers = {
|
|
||||||
lsp_zero.default_setup,
|
|
||||||
lua_ls = function()
|
|
||||||
local lua_opts = lsp_zero.nvim_lua_ls()
|
|
||||||
require('lspconfig').lua_ls.setup(lua_opts)
|
|
||||||
end,
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
-- Cmp
|
-- Cmp
|
||||||
local cmp = require('cmp')
|
local cmp = require('cmp')
|
||||||
local cmp_select = {behavior = cmp.SelectBehavior.Select}
|
local cmp_select = {behavior = cmp.SelectBehavior.Select}
|
||||||
|
@ -43,16 +43,12 @@ return require('lazy').setup({
|
|||||||
dependencies = {
|
dependencies = {
|
||||||
-- LSP Support
|
-- LSP Support
|
||||||
"neovim/nvim-lspconfig", -- Required
|
"neovim/nvim-lspconfig", -- Required
|
||||||
'williamboman/mason.nvim', -- Optional
|
|
||||||
'williamboman/mason-lspconfig.nvim', -- Optional
|
|
||||||
|
|
||||||
-- Autocompletion
|
-- Autocompletion
|
||||||
'hrsh7th/nvim-cmp', -- Required
|
'hrsh7th/nvim-cmp', -- Required
|
||||||
'hrsh7th/cmp-nvim-lsp', -- Required
|
'hrsh7th/cmp-nvim-lsp', -- Required
|
||||||
'hrsh7th/cmp-buffer', -- Optional
|
'hrsh7th/cmp-buffer', -- Optional
|
||||||
'hrsh7th/cmp-path', -- Optional
|
'hrsh7th/cmp-path', -- Optional
|
||||||
'saadparwaiz1/cmp_luasnip', -- Optional
|
|
||||||
'hrsh7th/cmp-nvim-lua', -- Optional
|
|
||||||
|
|
||||||
-- Snippets
|
-- Snippets
|
||||||
'L3MON4D3/LuaSnip', -- Required
|
'L3MON4D3/LuaSnip', -- Required
|
||||||
@ -70,50 +66,6 @@ return require('lazy').setup({
|
|||||||
branch = "harpoon2",
|
branch = "harpoon2",
|
||||||
dependencies = { "nvim-lua/plenary.nvim" },
|
dependencies = { "nvim-lua/plenary.nvim" },
|
||||||
},
|
},
|
||||||
-- focus plugins
|
|
||||||
{
|
|
||||||
"folke/twilight.nvim",
|
|
||||||
opts = {
|
|
||||||
dimming = {
|
|
||||||
alpha = 0.25,
|
|
||||||
color = { "Normal", "#ffffff" },
|
|
||||||
term_bg = "#000000",
|
|
||||||
inactive = false,
|
|
||||||
},
|
|
||||||
context = 10,
|
|
||||||
treesitter = true,
|
|
||||||
expand = {
|
|
||||||
"function",
|
|
||||||
"method",
|
|
||||||
"table",
|
|
||||||
"if_statement"
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"folke/zen-mode.nvim",
|
|
||||||
opts = {
|
|
||||||
{
|
|
||||||
window = {
|
|
||||||
backdrop = 0.95,
|
|
||||||
width = 120,
|
|
||||||
height = 1,
|
|
||||||
},
|
|
||||||
plugins = {
|
|
||||||
options = {
|
|
||||||
enabled = true,
|
|
||||||
ruler = false,
|
|
||||||
showcmd = false,
|
|
||||||
},
|
|
||||||
twilight = { enabled = true },
|
|
||||||
},
|
|
||||||
on_open = function(win)
|
|
||||||
end,
|
|
||||||
on_close = function()
|
|
||||||
end,
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
-- obsidian
|
-- obsidian
|
||||||
{
|
{
|
||||||
"epwalsh/obsidian.nvim",
|
"epwalsh/obsidian.nvim",
|
||||||
@ -136,54 +88,4 @@ return require('lazy').setup({
|
|||||||
enable = true
|
enable = true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
-- ollama
|
|
||||||
{
|
|
||||||
"nomnivore/ollama.nvim",
|
|
||||||
dependencies = {
|
|
||||||
"nvim-lua/plenary.nvim",
|
|
||||||
},
|
|
||||||
|
|
||||||
-- All the user commands added by the plugin
|
|
||||||
cmd = { "Ollama", "OllamaModel", "OllamaServe", "OllamaServeStop" },
|
|
||||||
|
|
||||||
keys = {
|
|
||||||
-- Sample keybind for prompt menu. Note that the <c-u> is important for selections to work properly.
|
|
||||||
{
|
|
||||||
"<leader>oo",
|
|
||||||
":<c-u>lua require('ollama').prompt()<cr>",
|
|
||||||
desc = "ollama prompt",
|
|
||||||
mode = { "n", "v" },
|
|
||||||
},
|
|
||||||
|
|
||||||
-- Sample keybind for direct prompting. Note that the <c-u> is important for selections to work properly.
|
|
||||||
{
|
|
||||||
"<leader>oG",
|
|
||||||
":<c-u>lua require('ollama').prompt('Generate_Code')<cr>",
|
|
||||||
desc = "ollama Generate Code",
|
|
||||||
mode = { "n", "v" },
|
|
||||||
},
|
|
||||||
},
|
|
||||||
|
|
||||||
---@type Ollama.Config
|
|
||||||
opts = {
|
|
||||||
model = "codellama",
|
|
||||||
url = "factory.lan:11434",
|
|
||||||
serve = {
|
|
||||||
on_start = false,
|
|
||||||
command = "ollama",
|
|
||||||
args = { "serve" },
|
|
||||||
stop_command = "pkill",
|
|
||||||
stop_args = { "-SIGTERM", "ollama" },
|
|
||||||
},
|
|
||||||
-- View the actual default prompts in ./lua/ollama/prompts.lua
|
|
||||||
prompts = {
|
|
||||||
Sample_Prompt = {
|
|
||||||
prompt = "This is a sample prompt that receives $input and $sel(ection), among others.",
|
|
||||||
input_label = "> ",
|
|
||||||
model = "mistral",
|
|
||||||
action = "display",
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user