Dropped AI integration, inline diagnostics, orgmode completion

Keymaps:

- key binding for viewing git log of current file: <space>=l
- blink keybindings simplified, added orgmode as source

Plugins:
- folke todo comments disabled
- dropped all AI integration
- added tiny-inline-diagnostic for easier and(!) wrapped diagnostic
  messages
- added sqlua.ncim plugin to connect to SQL databases
This commit is contained in:
2025-09-08 08:28:03 +02:00
parent 3ac01d9776
commit 4bd4d87f5b
4 changed files with 59 additions and 177 deletions

View File

@@ -46,13 +46,16 @@ require("lazy").setup({
--
-- See :h blink-cmp-config-keymap for defining your own keymap
keymap = {
preset = 'enter',
['<Up>'] = { 'select_prev', 'fallback' },
['<Down>'] = { 'select_next', 'fallback' },
['<S-Tab>'] = { 'select_prev', 'fallback' },
['<Tab>'] = { 'select_next', 'fallback' },
-- preset = 'enter',
preset = 'default',
-- ['<Up>'] = { 'select_prev', 'fallback' },
-- ['<Down>'] = { 'select_next', 'fallback' },
-- ['<S-Tab>'] = { 'select_prev', 'fallback' },
-- ['<Tab>'] = { 'select_next', 'fallback' },
['<CR>'] = { 'select_and_accept', 'fallback' },
['<C-space>'] = { 'show', 'fallback' },
['<C-space>'] = { 'show_and_insert', 'fallback' },
-- ['<C-space>'] = { 'show', 'fallback' },
-- ['<C-n>'] = { 'accept', 'fallback' },
},
signature = { enabled = true },
@@ -80,7 +83,19 @@ require("lazy").setup({
-- Default list of enabled providers defined so that you can extend it
-- elsewhere in your config, without redefining it, due to `opts_extend`
sources = {
default = { 'lsp', 'path', 'snippets', 'buffer' },
default = { 'lsp', 'path', 'snippets', 'buffer', 'orgmode' },
-- per_filetype = {
-- org = { 'orgmode' }
-- },
providers = {
orgmode = {
name = 'Orgmode',
module = 'orgmode.org.autocompletion.blink',
fallbacks = { 'lsp', 'path', 'snippets', 'buffer' },
-- fallbacks = { 'buffer' },
},
},
},
snippets = { preset = 'luasnip' },
@@ -385,15 +400,15 @@ require("lazy").setup({
-- TODO, WARN, HACK, PERF, NOTE, TEST and others highlighting and searching
{
"folke/todo-comments.nvim",
dependencies = { "nvim-lua/plenary.nvim" },
opts = {
-- your configuration comes here
-- or leave it empty to use the default settings
-- refer to the configuration section below
}
},
-- {
-- "folke/todo-comments.nvim",
-- dependencies = { "nvim-lua/plenary.nvim" },
-- opts = {
-- -- your configuration comes here
-- -- or leave it empty to use the default settings
-- -- refer to the configuration section below
-- }
-- },
-- highlight word under cursor
{
@@ -450,6 +465,7 @@ require("lazy").setup({
},
},
-- show indent markers
{
"lukas-reineke/indent-blankline.nvim",
@@ -459,166 +475,32 @@ require("lazy").setup({
opts = {},
},
-- ollama and LLM integration
-- improved (wrapping!) diagnostics
{
{
"huynle/ogpt.nvim",
event = "VeryLazy",
opts = {
default_provider = "ollama",
edgy = true, -- enable this!
single_window = false, -- set this to true if you want only one OGPT window to appear at a time
providers = {
ollama = {
api_host = os.getenv("OLLAMA_API_HOST") or "http://localhost:11434",
api_key = os.getenv("OLLAMA_API_KEY") or "",
model = "llama3.2-vision:sl",
}
"rachartier/tiny-inline-diagnostic.nvim",
event = "VeryLazy", -- one of LspAttach, VeryLazy
priority = 1000, -- needs to be loaded in first
config = function()
require('tiny-inline-diagnostic').setup({
options = {
use_icons_from_diagnostic = true,
enable_on_insert = true,
show_all_diags_on_cursorline = true,
}
},
dependencies = {
"MunifTanjim/nui.nvim",
"nvim-lua/plenary.nvim",
"nvim-telescope/telescope.nvim"
}
},
{
"folke/edgy.nvim",
event = "VeryLazy",
init = function()
vim.opt.laststatus = 3
vim.opt.splitkeep = "screen" -- or "topline" or "screen"
end,
opts = {
exit_when_last = false,
animate = {
enabled = false,
},
wo = {
winbar = true,
winfixwidth = true,
winfixheight = false,
winhighlight = "WinBar:EdgyWinBar,Normal:EdgyNormal",
spell = false,
signcolumn = "no",
},
keys = {
-- -- close window
["q"] = function(win)
win:close()
end,
-- close sidebar
["Q"] = function(win)
win.view.edgebar:close()
end,
-- increase width
["<S-Right>"] = function(win)
win:resize("width", 3)
end,
-- decrease width
["<S-Left>"] = function(win)
win:resize("width", -3)
end,
-- increase height
["<S-Up>"] = function(win)
win:resize("height", 3)
end,
-- decrease height
["<S-Down>"] = function(win)
win:resize("height", -3)
end,
},
right = {
{
title = "OGPT Popup",
ft = "ogpt-popup",
size = { width = 0.2 },
wo = {
wrap = true,
},
},
{
title = "OGPT Parameters",
ft = "ogpt-parameters-window",
size = { height = 6 },
wo = {
wrap = true,
},
},
{
title = "OGPT Template",
ft = "ogpt-template",
size = { height = 6 },
},
{
title = "OGPT Sessions",
ft = "ogpt-sessions",
size = { height = 6 },
wo = {
wrap = true,
},
},
{
title = "OGPT System Input",
ft = "ogpt-system-window",
size = { height = 6 },
},
{
title = "OGPT",
ft = "ogpt-window",
size = { height = 0.5 },
wo = {
wrap = true,
},
},
{
title = "OGPT {{{selection}}}",
ft = "ogpt-selection",
size = { width = 80, height = 4 },
wo = {
wrap = true,
},
},
{
title = "OGPt {{{instruction}}}",
ft = "ogpt-instruction",
size = { width = 80, height = 4 },
wo = {
wrap = true,
},
},
{
title = "OGPT Chat",
ft = "ogpt-input",
size = { width = 80, height = 4 },
wo = {
wrap = true,
},
},
},
},
},
-- improved (wrapping!) diagnostics
{
"rachartier/tiny-inline-diagnostic.nvim",
event = "VeryLazy", -- one of LspAttach, VeryLazy
priority = 1000, -- needs to be loaded in first
config = function()
require('tiny-inline-diagnostic').setup({
options = {
use_icons_from_diagnostic = true,
enable_on_insert = true,
show_all_diags_on_cursorline = true,
}
})
vim.diagnostic.config({ virtual_text = false }) -- Only if needed in your configuration, if you already have native LSP diagnostics
end
},
-- new plugins here
})
vim.diagnostic.config({ virtual_text = false }) -- Only if needed in your configuration, if you already have native LSP diagnostics
end
},
-- 2025-05-21 not yet clear if this is a good thing or not
{
'xemptuous/sqlua.nvim',
lazy = true,
cmd = 'SQLua',
config = function() require('sqlua').setup() end
},
-- new plugins BEFORE here
})