This commit is contained in:
2025-08-15 16:37:31 -05:00
parent 450f33f7dc
commit f5fd3c0344
30 changed files with 1482 additions and 1605 deletions

View File

@@ -0,0 +1,10 @@
{
"runtime.version": "LuaJIT",
"runtime.path": [
"lua/?.lua",
"lua/?/init.lua"
],
"diagnostics.globals": ["vim"],
"workspace.checkThirdParty": false,
"workspace.library": [ "$VIMRUNTIME" ]
}

View File

@@ -1 +1 @@
require("config")
require('config')

View File

@@ -1,55 +0,0 @@
{
"LuaSnip": { "branch": "master", "commit": "458560534a73f7f8d7a11a146c801db00b081df0" },
"avante.nvim": { "branch": "main", "commit": "c10e383019280edf6433b422603be45294c9ccf5" },
"barbar.nvim": { "branch": "master", "commit": "53b5a2f34b68875898f0531032fbf090e3952ad7" },
"cloak.nvim": { "branch": "main", "commit": "648aca6d33ec011dc3166e7af3b38820d01a71e4" },
"cmp-buffer": { "branch": "main", "commit": "b74fab3656eea9de20a9b8116afa3cfc4ec09657" },
"cmp-dotenv": { "branch": "main", "commit": "4dd53aab60982f1f75848aec5e6214986263325e" },
"cmp-emoji": { "branch": "main", "commit": "e8398e2adf512a03bb4e1728ca017ffeac670a9f" },
"cmp-nerdfont": { "branch": "main", "commit": "e97482344ebed29093015a18c155057adf5c842b" },
"cmp-npm": { "branch": "main", "commit": "2337f109f51a09297596dd6b538b70ccba92b4e4" },
"cmp-nvim-lsp": { "branch": "main", "commit": "a8912b88ce488f411177fc8aed358b04dc246d7b" },
"cmp-nvim-lsp-document-symbol": { "branch": "main", "commit": "f94f7ba948e32cd302caba1c2ca3f7c697fb4fcf" },
"cmp-nvim-lua": { "branch": "main", "commit": "f12408bdb54c39c23e67cab726264c10db33ada8" },
"cmp-path": { "branch": "main", "commit": "c6635aae33a50d6010bf1aa756ac2398a2d54c32" },
"cmp-tw2css": { "branch": "main", "commit": "1abe0eebcb57fcbd5538d054f0db61f4e4a1302b" },
"cmp_luasnip": { "branch": "master", "commit": "98d9cb5c2c38532bd9bdb481067b20fea8f32e90" },
"conform.nvim": { "branch": "master", "commit": "8132ec733eed3bf415b97b76797ca41b59f51d7d" },
"dressing.nvim": { "branch": "master", "commit": "2d7c2db2507fa3c4956142ee607431ddb2828639" },
"fidget.nvim": { "branch": "main", "commit": "d9ba6b7bfe29b3119a610892af67602641da778e" },
"friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" },
"fzf-lua": { "branch": "main", "commit": "3d4342120cf12f36b60a8161a8835b111ec5ec9a" },
"gitsigns.nvim": { "branch": "main", "commit": "1b0350ab707713b2bc6c236151f1a324175347b1" },
"image.nvim": { "branch": "master", "commit": "4c51d6202628b3b51e368152c053c3fb5c5f76f2" },
"img-clip.nvim": { "branch": "main", "commit": "d8b6b030672f9f551a0e3526347699985a779d93" },
"lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" },
"leetcode.nvim": { "branch": "master", "commit": "db7e1cd6b9191b34b4c1f2f96e4e3949cde9f951" },
"lspkind.nvim": { "branch": "master", "commit": "d79a1c3299ad0ef94e255d045bed9fa26025dab6" },
"lualine.nvim": { "branch": "master", "commit": "a94fc68960665e54408fe37dcf573193c4ce82c9" },
"mason-lspconfig.nvim": { "branch": "main", "commit": "c4c84f4521d62de595c0d0f718a9a40c1890c8ce" },
"mason.nvim": { "branch": "main", "commit": "8024d64e1330b86044fed4c8494ef3dcd483a67c" },
"mcphub.nvim": { "branch": "main", "commit": "1eb7bec18f3927ee7fa468e0a176812383669596" },
"mini.hipatterns": { "branch": "main", "commit": "d71c21167d6bd5f21c9ecf90912c510f9edfc02b" },
"neo-tree.nvim": { "branch": "v3.x", "commit": "f481de16a0eb59c985abac8985e3f2e2f75b4875" },
"nerdcommenter": { "branch": "master", "commit": "02a3b6455fa07b61b9440a78732f1e9b7876c991" },
"nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" },
"nvim-autopairs": { "branch": "master", "commit": "2647cce4cb64fb35c212146663384e05ae126bdf" },
"nvim-cmp": { "branch": "main", "commit": "b5311ab3ed9c846b585c0c15b7559be131ec4be9" },
"nvim-lsp-file-operations": { "branch": "master", "commit": "9744b738183a5adca0f916527922078a965515ed" },
"nvim-lspconfig": { "branch": "master", "commit": "6bba673aa8993eceec233be17b42ddfb9540794b" },
"nvim-notify": { "branch": "master", "commit": "a22f5d7ac511c2df2fd3290a9f04c48d5a822e2e" },
"nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" },
"nvim-treesitter-context": { "branch": "master", "commit": "1a1a7c5d6d75cb49bf64049dafab15ebe294a79f" },
"nvim-ts-autotag": { "branch": "main", "commit": "a1d526af391f6aebb25a8795cbc05351ed3620b5" },
"nvim-web-devicons": { "branch": "master", "commit": "19d6211c78169e78bab372b585b6fb17ad974e82" },
"nvim-window-picker": { "branch": "main", "commit": "6382540b2ae5de6c793d4aa2e3fe6dbb518505ec" },
"playground": { "branch": "master", "commit": "ba48c6a62a280eefb7c85725b0915e021a1a0749" },
"plenary.nvim": { "branch": "master", "commit": "857c5ac632080dba10aae49dba902ce3abf91b35" },
"render-markdown.nvim": { "branch": "main", "commit": "24aacee83544ca113055564ed22be7852067c342" },
"rest.nvim": { "branch": "main", "commit": "de9726ab956e30202aafbcdea83c1d6bffe54227" },
"supermaven-nvim": { "branch": "main", "commit": "07d20fce48a5629686aefb0a7cd4b25e33947d50" },
"telescope.nvim": { "branch": "master", "commit": "a0bbec21143c7bc5f8bb02e0005fa0b982edc026" },
"tokyonight.nvim": { "branch": "main", "commit": "057ef5d260c1931f1dffd0f052c685dcd14100a3" },
"trouble.nvim": { "branch": "main", "commit": "85bedb7eb7fa331a2ccbecb9202d8abba64d37b3" },
"undotree": { "branch": "master", "commit": "b951b87b46c34356d44aa71886aecf9dd7f5788a" }
}

View File

@@ -0,0 +1,61 @@
local augroup = vim.api.nvim_create_augroup
local gib_group = augroup('Gib', {})
local autocmd = vim.api.nvim_create_autocmd
local createcmd = vim.api.nvim_create_user_command
local yank_group = augroup('HighlightYank', {})
function R(name)
require("plenary.reload").reload_module(name)
end
autocmd('TextYankPost', {
group = yank_group,
pattern = '*',
callback = function()
vim.highlight.on_yank({
higroup = 'IncSearch',
timeout = 40,
})
end,
})
autocmd({"BufWritePre"}, {
group = gib_group,
pattern = "*",
command = [[%s/\s\+$//e]],
})
autocmd({'BufWritePost'}, {
pattern = 'init.lua',
command = 'source <afile>',
})
autocmd('LspAttach', {
group = gib_group,
callback = function(e)
local opts = { buffer = e.buf }
vim.keymap.set('n', '<leader>kf', vim.lsp.buf.format)
vim.keymap.set("n", "gd", function() vim.lsp.buf.definition() end, opts)
vim.keymap.set("n", "<leader>kw", function() vim.lsp.buf.workspace_symbol() end, opts)
vim.keymap.set("n", "<leader>kd", function() vim.diagnostic.open_float() end, opts)
vim.keymap.set("n", "<leader>vca", function() vim.lsp.buf.code_action() end, opts)
vim.keymap.set("n", "<leader>re", function() vim.lsp.buf.references() end, opts)
vim.keymap.set("n", "<leader>rn", function() vim.lsp.buf.rename() end, opts)
vim.keymap.set("i", "<C-h>", function() vim.lsp.buf.signature_help() end, opts)
end
})
createcmd("Format", function(args)
local range
if args.count ~= -1 then
local start_line = vim.fn.line("'<")
local end_line = vim.fn.line("'>")
range = { start = { start_line, 0 }, ["end"] = { end_line, 0 } }
end
require("conform").format({
async = true,
lsp_fallback = true, -- if no external formatter, use LSP
range = range,
})
end, { range = true, desc = "Format current buffer or range" })
vim.keymap.set({ "n", "v" }, "<leader>fk", ":Format<CR>", { silent = true, desc = "Format" })

View File

@@ -1,65 +1,4 @@
require('config.set')
require('config.remap')
require("config.lazy")
local augroup = vim.api.nvim_create_augroup
local GibGroup = augroup('Gib', {})
local autocmd = vim.api.nvim_create_autocmd
local yank_group = augroup('HighlightYank', {})
function R(name)
require("plenary.reload").reload_module(name)
end
vim.filetype.add({
extension = {
templ = 'templ',
}
})
autocmd('TextYankPost', {
group = yank_group,
pattern = '*',
callback = function()
vim.highlight.on_yank({
higroup = 'IncSearch',
timeout = 40,
})
end,
})
autocmd({"BufWritePre"}, {
group = GibGroup,
pattern = "*",
command = [[%s/\s\+$//e]],
})
autocmd('BufEnter', {
group = GibGroup,
callback = function()
if vim.bo.filetype == "zig" then
vim.cmd.colorscheme("tokyonight-moon")
else
vim.cmd.colorscheme("tokyonight-moon")
end
end
})
autocmd('LspAttach', {
group = GibGroup,
callback = function(e)
local opts = { buffer = e.buf }
vim.keymap.set("n", "gd", function() vim.lsp.buf.definition() end, opts)
vim.keymap.set("n", "<leader>H", function() vim.lsp.buf.hover() end, opts)
vim.keymap.set("n", "<leader>kw", function() vim.lsp.buf.workspace_symbol() end, opts)
vim.keymap.set("n", "<leader>kd", function() vim.diagnostic.open_float() end, opts)
vim.keymap.set("n", "<leader>vca", function() vim.lsp.buf.code_action() end, opts)
vim.keymap.set("n", "<leader>re", function() vim.lsp.buf.references() end, opts)
vim.keymap.set("n", "<leader>rn", function() vim.lsp.buf.rename() end, opts)
vim.keymap.set("i", "<C-h>", function() vim.lsp.buf.signature_help() end, opts)
vim.keymap.set("n", "[d", function() vim.diagnostic.goto_next() end, opts)
vim.keymap.set("n", "]d", function() vim.diagnostic.goto_prev() end, opts)
end
})
require('config.options')
require('config.keymaps')
require('plugins')
require('config.autocmd')

View File

@@ -0,0 +1,40 @@
vim.g.mapleader = ' '
vim.keymap.set('n', '<leader><leader>s', ':update<CR> :source<CR>')
vim.keymap.set('n', '<leader><leader>x', ':!chmod +x %<CR>', { silent = true })
vim.keymap.set({'n', 'v', 'x'}, '<leader>h', '<C-w>h')
vim.keymap.set({'n', 'v', 'x'}, '<leader>j', '<C-w>j')
vim.keymap.set({'n', 'v', 'x'}, '<leader>k', '<C-w>k')
vim.keymap.set({'n', 'v', 'x'}, '<leader>l', '<C-w>l')
vim.keymap.set('n', '<leader>w', ':write<CR>')
vim.keymap.set('n', '<leader>q', ':quit<CR>')
-- Move the selected lines up or down one line and reselect
vim.keymap.set('v', 'J', ':m \'>+1<CR>gv=gv')
vim.keymap.set('v', 'K', ':m \'<-2<CR>gv=gv')
-- Join the current line with the line below and reposition the cursor
vim.keymap.set('n', 'J', 'mzJ`z')
-- Scroll down or up and reposition the cursor
vim.keymap.set('n', '<C-d>', '<C-d>zz')
vim.keymap.set('n', '<C-u>', '<C-u>zz')
-- Search forward and reposition the cursor
vim.keymap.set('n', 'n', 'nzzzv')
-- Search backward and reposition the cursor
vim.keymap.set('n', 'N', 'Nzzzv')
-- Paste the selection from the system clipboard
vim.keymap.set({'n', 'v', 'x'}, '<leader>p', [["+p]])
vim.keymap.set({'n', 'v', 'x'}, '<leader>P', [["+P]])
-- Move selected text to the black hole register & replace with copied text.
vim.keymap.set('x', '<leader>v', [["_dP]])
-- Yank (copy) the selection to the system clipboard
vim.keymap.set({'n', 'v'}, '<leader>y', [["+y]])
-- Yank (copy) the entire buffer to the system clipboard
vim.keymap.set('n', '<leader>yy', [["+Y]])
-- Yank all the text in the file to the system clipboard
vim.keymap.set('n', '<leader>YY', 'gg"+yG')
-- Delete the selection without yanking (copying) it
vim.keymap.set({'n', 'v'}, '<leader>d', [["_d]])
-- Delete the line without yanking (copying) it
vim.keymap.set('n', '<leader>dd', [["_dd]])
-- Map Q in Normal mode to do nothing (nop)
vim.keymap.set('n', 'Q', '<nop>')
-- Perform a search and replace operation using the word under the cursor
vim.keymap.set('n', '<leader>sr', [[:%s/\<<C-r><C-w>\>/<C-r><C-w>/gI<Left><Left><Left>]])

View File

@@ -1,27 +0,0 @@
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not (vim.uv or vim.loop).fs_stat(lazypath) then
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
if vim.v.shell_error ~= 0 then
vim.api.nvim_echo({
{ "Failed to clone lazy.nvim:\n", "ErrorMsg" },
{ out, "WarningMsg" },
{ "\nPress any key to exit..." },
}, true, {})
vim.fn.getchar()
os.exit(1)
end
end
vim.opt.rtp:prepend(lazypath)
--vim.g.mapleader = " "
--vim.g.maplocalleader = "\\"
-- Setup lazy.nvim
require("lazy").setup({
spec = {
{ import = 'plugins' },
},
install = { colorscheme = { "tokyonight-moon" } },
-- automatically check for plugin updates
--checker = { enabled = true },
})

View File

@@ -0,0 +1,21 @@
vim.o.number = true
vim.o.relativenumber = true
vim.o.winborder = 'rounded'
vim.o.tabstop = 2
vim.o.softtabstop = 2
vim.o.shiftwidth = 2
vim.o.expandtab = true
vim.o.smartindent = true
vim.o.swapfile = false
vim.o.undodir = os.getenv('HOME') .. '/.vim/undodir'
vim.o.undofile = true
vim.o.hlsearch = true
vim.o.incsearch = true
vim.o.termguicolors = true
vim.o.scrolloff = 4
vim.o.signcolumn = 'yes'
vim.o.updatetime = 50
vim.opt.isfname:append('@-@')
vim.cmd([[set list]])
vim.cmd([[set listchars=trail:⋅,nbsp:⋅,tab:\ \ ]])
vim.cmd(':hi statusline guibg=NONE')

View File

@@ -1,71 +0,0 @@
-- Remaps
---------------------------------------------
-- Set leader to space
vim.g.mapleader = " "
-- Move the selected lines up or down one line and reselect
vim.keymap.set("v", "J", ":m '>+1<CR>gv=gv")
vim.keymap.set("v", "K", ":m '<-2<CR>gv=gv")
-- Join the current line with the line below and reposition the cursor
vim.keymap.set("n", "J", "mzJ`z")
-- Scroll down or up and reposition the cursor
vim.keymap.set("n", "<C-d>", "<C-d>zz")
vim.keymap.set("n", "<C-u>", "<C-u>zz")
-- Search forward and reposition the cursor
vim.keymap.set("n", "n", "nzzzv")
-- Search backward and reposition the cursor
vim.keymap.set("n", "N", "Nzzzv")
-- Paste the selection from the system clipboard
vim.keymap.set({"n", "v"}, "<leader>v", [["+p]])
vim.keymap.set({"n", "v"}, "<leader>V", [["+P]])
-- Move selected text to the black hole register & replace with copied text.
vim.keymap.set("x", "<leader>p", [["_dP]])
-- Yank (copy) the selection to the system clipboard
vim.keymap.set({"n", "v"}, "<leader>y", [["+y]])
-- Yank (copy) the entire buffer to the system clipboard
vim.keymap.set("n", "<leader>Y", [["+Y]])
-- Yank all the text in the file to the system clipboard
vim.keymap.set("n", "<leader>YY", "gg\"+yG")
-- Delete the selection without yanking (copying) it
vim.keymap.set({"n", "v"}, "<leader>d", [["_d]])
-- Delete the line without yanking (copying) it
vim.keymap.set("n", "<leader>dd", [["_dd]])
-- Map Q in Normal mode to do nothing (nop)
vim.keymap.set("n", "Q", "<nop>")
-- Format the current buffer using the language server protocol (LSP)
vim.keymap.set("n", "<leader>kf", vim.lsp.buf.format)
-- Perform a search and replace operation using the word under the cursor
vim.keymap.set("n", "<leader>sr", [[:%s/\<<C-r><C-w>\>/<C-r><C-w>/gI<Left><Left><Left>]])
-- Make the current file executable (chmod +x)
vim.keymap.set("n", "<leader>x", "<cmd>!chmod +x %<CR>", { silent = true })
-- Source the current file
vim.keymap.set("n", "<leader><leader>", vim.cmd.so)
-- Jump to the next location in the quickfix list and reposition the cursor
-- vim.keymap.set("n", "<C-k>", "<cmd>cnext<CR>zz")
-- Jump to the previous location in the quickfix list and reposition the cursor
-- vim.keymap.set("n", "<C-j>", "<cmd>cprev<CR>zz")
-- Jump to the next location in the location list and reposition the cursor
--vim.keymap.set("n", "<leader>k", "<cmd>lnext<CR>zz")
-- Jump to the previous location in the location list and reposition the cursor
--vim.keymap.set("n", "<leader>j", "<cmd>lprev<CR>zz")

View File

@@ -1,34 +0,0 @@
vim.opt.nu = true
vim.opt.relativenumber = true
vim.opt.tabstop = 2
vim.opt.softtabstop = 2
vim.opt.shiftwidth = 2
vim.opt.expandtab = true
vim.opt.smartindent = true
vim.opt.wrap = true
vim.opt.swapfile = false
vim.opt.backup = false
vim.opt.undodir = os.getenv("HOME") .. "/.vim/undodir"
vim.opt.undofile = true
vim.opt.hlsearch = false
vim.opt.incsearch = true
vim.opt.termguicolors = true
vim.opt.scrolloff = 8
vim.opt.signcolumn = "yes"
vim.opt.isfname:append("@-@")
vim.opt.updatetime = 50
vim.cmd([[set list]])
--vim.cmd([[set listchars=trail:⋅]])
vim.cmd([[set listchars=trail:⋅,nbsp:⋅,tab:\ \ ]])
vim.opt.colorcolumn = "100"
vim.o.background = "dark" -- or "light" for light mode
--vim.cmd([[colorscheme tokyonight-moon]])

View File

@@ -1,29 +1,31 @@
return {
{
"yetone/avante.nvim",
event = "VeryLazy",
version = false, -- Never set this value to "*"! Never!
opts = {
---@alias Provider "claude" | "openai" | "azure" | "gemini" | "cohere" | "copilot" | string
provider = "claude", -- The provider used in Aider mode or in the planning phase of Cursor Planning Mode
---@alias Mode "agentic" | "legacy"
mode = "agentic", -- The default mode for interaction. "agentic" uses tools to automatically generate code, "legacy" uses the old planning method to generate code.
-- WARNING: Since auto-suggestions are a high-frequency operation and therefore expensive,
-- currently designating it as `copilot` provider is dangerous because: https://github.com/yetone/avante.nvim/issues/1048
-- Of course, you can reduce the request frequency by increasing `suggestion.debounce`.
auto_suggestions_provider = "claude",
vim.pack.add({
{ src = 'https://github.com/yetone/avante.nvim' },
{ src = 'https://github.com/nvim-lua/plenary.nvim' },
{ src = 'https://github.com/MunifTanjim/nui.nvim' },
{ src = 'https://github.com/hrsh7th/nvim-cmp' },
{ src = 'https://github.com/nvim-treesitter/nvim-treesitter' },
{ src = 'https://github.com/stevearc/dressing.nvim' },
{ src = 'https://github.com/nvim-tree/nvim-web-devicons' },
{ src = 'https://github.com/HakonHarnes/img-clip.nvim' },
{ src = 'https://github.com/MeanderingProgrammer/render-markdown.nvim' },
{ src = 'https://github.com/ravitemer/mcphub.nvim' },
})
require'avante'.setup({
provider = 'openai',
auto_suggestions_provider = 'openai',
providers = {
claude = {
endpoint = "https://api.anthropic.com",
model = "claude-sonnet-4-20250514",
endpoint = 'https://api.anthropic.com',
model = 'claude-sonnet-4-20250514',
timeout = 30000,
extra_request_body = {
temperature = 0.75,
max_tokens = 4096,
},
},
openai = {
endpoint = "https://api.openai.com/v1",
model = "gpt-4o",
endpoint = 'https://api.openai.com/v1',
model = 'gpt-5',
extra_request_body = {
timeout = 30000,
temperature = 0,
@@ -31,150 +33,141 @@ return {
},
},
},
rag_service = {
enabled = false,
host_path = '/home/gib/Documents/Code',
runner = 'docker',
llm = {
provider = 'openai',
endpoint = 'https://api.openai.com/v1',
api_key = 'OPENAI_API_KEY',
model = 'gpt-4o-mini',
extra = {
temperature = 0.7,
max_tokens = 512,
timeout = 60,
},
},
embed = {
provider = 'openai',
endpoint = 'https://api.openai.com/v1',
api_key = 'OPENAI_API_KEY',
model = 'text-embedding-3-large',
extra = nil,
},
docker_extra_args = '',
},
web_search_engine = {
provider = "searxng",
provider = 'searxng',
proxy = nil,
},
system_prompt = function()
local hub = require("mcphub").get_hub_instance()
return hub and hub:get_active_servers_prompt() or ""
local hub = require('mcphub').get_hub_instance()
return hub and hub:get_active_servers_prompt() or ''
end,
custom_tools = function()
return {
require("mcphub.extensions.avante").mcp_tool(),
require('mcphub.extensions.avante').mcp_tool(),
}
end,
---Specify the special dual_boost mode
---1. enabled: Whether to enable dual_boost mode. Default to false.
---2. first_provider: The first provider to generate response. Default to "openai".
---3. second_provider: The second provider to generate response. Default to "claude".
---4. prompt: The prompt to generate response based on the two reference outputs.
---5. timeout: Timeout in milliseconds. Default to 60000.
---How it works:
--- When dual_boost is enabled, avante will generate two responses from the first_provider and second_provider respectively. Then use the response from the first_provider as provider1_output and the response from the second_provider as provider2_output. Finally, avante will generate a response based on the prompt and the two reference outputs, with the default Provider as normal.
---Note: This is an experimental feature and may not work as expected.
dual_boost = {
enabled = false,
first_provider = "openai",
second_provider = "claude",
prompt = "Based on the two reference outputs below, generate a response that incorporates elements from both but reflects your own judgment and unique perspective. Do not provide any explanation, just give the response directly. Reference Output 1: [{{provider1_output}}], Reference Output 2: [{{provider2_output}}]",
timeout = 60000, -- Timeout in milliseconds
},
behaviour = {
auto_suggestions = false, -- Experimental stage
auto_suggestions = false,
auto_set_highlight_group = true,
auto_set_keymaps = true,
auto_apply_diff_after_generation = false,
support_paste_from_clipboard = false,
minimize_diff = true, -- Whether to remove unchanged lines when applying a code block
enable_token_counting = true, -- Whether to enable token counting. Default to true.
minimize_diff = true,
enable_token_counting = true,
auto_approve_tool_permissions = true,
},
mappings = {
--- @class AvanteConflictMappings
diff = {
ours = "co",
theirs = "ct",
all_theirs = "ca",
both = "cb",
cursor = "cc",
next = "]x",
prev = "[x",
ours = 'co',
theirs = 'ct',
all_theirs = 'ca',
both = 'cb',
cursor = 'cc',
next = ']x',
prev = '[x',
},
suggestion = {
accept = "<M-l>",
next = "<M-]>",
prev = "<M-[>",
dismiss = "<C-]>",
accept = '<M-l>',
next = '<M-]>',
prev = '<M-[>',
dismiss = '<C-]>',
},
jump = {
next = "]]",
prev = "[[",
next = ']]',
prev = '[[',
},
submit = {
normal = "<CR>",
insert = "<C-s>",
normal = '<CR>',
insert = '<C-s>',
},
cancel = {
normal = { "<C-c>", "<Esc>", "q" },
insert = { "<C-c>" },
normal = { '<C-c>', '<Esc>', 'q' },
insert = { '<C-c>' },
},
sidebar = {
apply_all = "A",
apply_cursor = "a",
retry_user_request = "r",
edit_user_request = "e",
switch_windows = "<Tab>",
reverse_switch_windows = "<S-Tab>",
remove_file = "d",
add_file = "@",
close = { "<Esc>", "q" },
close_from_input = nil, -- e.g., { normal = "<Esc>", insert = "<C-d>" }
apply_all = 'A',
apply_cursor = 'a',
retry_user_request = 'r',
edit_user_request = 'e',
switch_windows = '<Tab>',
reverse_switch_windows = '<S-Tab>',
remove_file = 'd',
add_file = '@',
close = { '<Esc>', 'q' },
close_from_input = nil,
},
},
hints = { enabled = true },
windows = {
---@type "right" | "left" | "top" | "bottom"
position = "right", -- the position of the sidebar
wrap = true, -- similar to vim.o.wrap
width = 35, -- default % based on available width
---@type 'right' | 'left' | 'top' | 'bottom'
position = 'right',
wrap = true,
width = 35,
sidebar_header = {
enabled = true, -- true, false to enable/disable the header
align = "center", -- left, center, right for title
enabled = true,
align = 'center',
rounded = true,
},
input = {
prefix = "> ",
height = 8, -- Height of the input window in vertical layout
prefix = '> ',
height = 8,
},
edit = {
border = "rounded",
start_insert = true, -- Start insert mode when opening the edit window
border = 'rounded',
start_insert = true,
},
ask = {
floating = false, -- Open the 'AvanteAsk' prompt in a floating window
start_insert = true, -- Start insert mode when opening the ask window
border = "rounded",
---@type "ours" | "theirs"
focus_on_apply = "ours", -- which diff to focus after applying
floating = false,
start_insert = true,
border = 'rounded',
---@type 'ours' | 'theirs'
focus_on_apply = 'ours',
},
},
highlights = {
---@type AvanteConflictHighlights
diff = {
current = "DiffText",
incoming = "DiffAdd",
current = 'DiffText',
incoming = 'DiffAdd',
},
},
--- @class AvanteConflictUserConfig
diff = {
autojump = true,
---@type string | fun(): any
list_opener = "copen",
--- Override the 'timeoutlen' setting while hovering over a diff (see :help timeoutlen).
--- Helps to avoid entering operator-pending mode with diff mappings starting with `c`.
--- Disable by setting to -1.
list_opener = 'copen',
override_timeoutlen = 500,
},
suggestion = {
debounce = 600,
throttle = 600,
debounce = 1000,
throttle = 1000,
},
},
build = "make", -- or `make BUILD_FROM_SOURCE=true`
dependencies = {
"nvim-treesitter/nvim-treesitter",
"stevearc/dressing.nvim",
"nvim-lua/plenary.nvim",
"MunifTanjim/nui.nvim",
"hrsh7th/nvim-cmp", -- autocompletion for avante commands and mentions
"ibhagwan/fzf-lua", -- for file_selector provider fzf
"nvim-tree/nvim-web-devicons", -- or echasnovski/mini.icons
{
-- support for image pasting
"HakonHarnes/img-clip.nvim",
event = "VeryLazy",
opts = {
-- recommended settings
})
require'img-clip'.setup({
default = {
embed_image_as_base64 = false,
prompt_for_file_name = false,
@@ -182,66 +175,46 @@ return {
insert_mode = true,
},
},
},
},
{
'MeanderingProgrammer/render-markdown.nvim',
opts = {
file_types = { "markdown", "Avante" },
},
ft = { "markdown", "Avante" },
},
},
},
{
"ravitemer/mcphub.nvim",
dependencies = {
"nvim-lua/plenary.nvim",
},
opts = {
config = vim.fn.expand("~/.config/mcphub/servers.json"), -- Absolute path to MCP Servers config file (will create if not exists)
port = 37373, -- The port `mcp-hub` server listens to
shutdown_delay = 60 * 10 * 000, -- Delay in ms before shutting down the server when last instance closes (default: 10 minutes)
use_bundled_binary = false, -- Use local `mcp-hub` binary (set this to true when using build = "bundled_build.lua")
mcp_request_timeout = 60000, --Max time allowed for a MCP tool or resource to execute in milliseconds, set longer for long running tasks
---Chat-plugin related options-----------------
auto_approve = false, -- Auto approve mcp tool calls
auto_toggle_mcp_servers = true, -- Let LLMs start and stop MCP servers automatically
})
require'render-markdown'.setup({
file_types = { 'markdown', 'Avante' },
})
require'mcphub'.setup({
config = vim.fn.expand('/home/gib/.config/mcphub/servers.json'),
port = 37373,
shutdown_delay = 60 * 10 * 000,
use_bundled_binary = false,
mcp_request_timeout = 60000,
auto_approve = true,
auto_toggle_mcp_servers = true,
extensions = {
avante = {
make_slash_commands = true, -- make /slash commands from MCP server prompts
}
make_slash_commands = true,
},
},
--- Plugin specific options-------------------
native_servers = {}, -- add your custom lua native servers here
native_servers = {},
ui = {
window = {
width = 0.8, -- 0-1 (ratio); "50%" (percentage); 50 (raw number)
height = 0.8, -- 0-1 (ratio); "50%" (percentage); 50 (raw number)
align = "center", -- "center", "top-left", "top-right", "bottom-left", "bottom-right", "top", "bottom", "left", "right"
relative = "editor",
width = 0.8,
height = 0.8,
align = 'center',
relative = 'editor',
zindex = 50,
border = "rounded", -- "none", "single", "double", "rounded", "solid", "shadow"
border = 'rounded',
},
wo = { -- window-scoped options (vim.wo)
winhl = "Normal:MCPHubNormal,FloatBorder:MCPHubBorder",
wo = {
winhl = 'Normal:MCPHubNormal,FloatBorder:MCPHubBorder',
},
},
on_ready = function(hub)
-- Called when hub is ready
end,
on_error = function(err)
-- Called on errors
end,
--on_ready = function(hub)
--end,
--on_error = function(err)
--end,
log = {
level = vim.log.levels.WARN,
to_file = false,
file_path = nil,
prefix = "MCPHub",
prefix = 'MCPHub',
},
},
build = "npm install -g mcp-hub@latest",
},
}
})

View File

@@ -1,38 +1,15 @@
return {
{
'romgrk/barbar.nvim', dependencies = {
'lewis6991/gitsigns.nvim', -- OPTIONAL: for git status
'nvim-tree/nvim-web-devicons', -- OPTIONAL: for file icons
},
init = function()
vim.g.barbar_auto_setup = false
end,
opts = {
vim.pack.add({
{ src = 'https://github.com/romgrk/barbar.nvim' },
{ src = 'https://github.com/lewis6991/gitsigns.nvim' },
{ src = 'https://github.com/nvim-tree/nvim-web-devicons' },
})
require'barbar'.setup({
animation = true,
insert_at_start = true,
},
version = '^1.0.0',
keys = {
-- Move to prev/next tab
{ "<C-h>", "<Cmd>BufferPrevious<CR>", mode = "n", desc = "Prev tab" },
{ "<C-l>", "<Cmd>BufferNext<CR>", mode = "n", desc = "Next tab" },
-- Re-order buffers
{ "<C-j>", "<Cmd>BufferMovePrevious<CR>", mode = "n", desc = "Move tab left" },
{ "<C-k>", "<Cmd>BufferMoveNext<CR>", mode = "n", desc = "Move tab right" },
-- Close buffers
{ "<C-q>", "<Cmd>BufferClose<CR>", mode = "n", desc = "Close tab" },
{ "<C-a>", "<Cmd>BufferCloseAllButCurrent<CR>", mode = "n", desc = "Close all but current" },
-- Goto tab in position…
{ "<leader>1", "<Cmd>BufferGoto 1<CR>", mode = "n", desc = "Go to tab 1" },
{ "<leader>2", "<Cmd>BufferGoto 2<CR>", mode = "n", desc = "Go to tab 2" },
{ "<leader>3", "<Cmd>BufferGoto 3<CR>", mode = "n", desc = "Go to tab 3" },
{ "<leader>4", "<Cmd>BufferGoto 4<CR>", mode = "n", desc = "Go to tab 4" },
{ "<leader>5", "<Cmd>BufferGoto 5<CR>", mode = "n", desc = "Go to tab 5" },
{ "<leader>6", "<Cmd>BufferGoto 6<CR>", mode = "n", desc = "Go to tab 6" },
{ "<leader>7", "<Cmd>BufferGoto 7<CR>", mode = "n", desc = "Go to tab 7" },
{ "<leader>8", "<Cmd>BufferGoto 8<CR>", mode = "n", desc = "Go to tab 8" },
{ "<leader>9", "<Cmd>BufferGoto 9<CR>", mode = "n", desc = "Go to tab 9" },
{ "<leader>0", "<Cmd>BufferLast<CR>", mode = "n", desc = "Go to last tab" },
},
},
}
insert_at_start = true
})
vim.keymap.set({'n'}, '<C-h>', ':BufferPrevious<CR>')
vim.keymap.set({'n'}, '<C-l>', ':BufferNext<CR>')
vim.keymap.set({'n'}, '<C-j>', ':BufferMovePrevious<CR>')
vim.keymap.set({'n'}, '<C-k>', ':BufferMoveNext<CR>')
vim.keymap.set({'n'}, '<C-q>', ':BufferClose<CR>')
vim.keymap.set({'n'}, '<C-a>', ':BufferCloseAllButCurrent<CR>')

View File

@@ -1,7 +1,7 @@
return {
{
'laytan/cloak.nvim',
opts = {
vim.pack.add({
{ src = 'https://github.com/laytan/cloak.nvim' },
})
require'cloak'.setup({
enabled = false,
cloak_character = "",
highlight_group = "Comment",
@@ -15,6 +15,4 @@ return {
cloak_pattern = "=.+"
},
},
},
},
}
})

View File

@@ -0,0 +1,13 @@
vim.pack.add({
{ src = 'https://github.com/folke/tokyonight.nvim' },
})
require('tokyonight').setup({
style = 'moon',
transparent = true,
on_colors = function(colors)
colors.comment = '#a0a7c5'
colors.fg_gutter = '#787f93'
colors.terminal_black = '#828bb8'
end,
})
vim.cmd('colorscheme tokyonight-moon')

View File

@@ -1,11 +1,8 @@
return {
{
"3rd/image.nvim",
event = "VeryLazy",
dependencies = {
"nvim-treesitter/nvim-treesitter",
},
opts = {
vim.pack.add({
{ src = 'https://github.com/3rd/image.nvim' },
{ src = 'https://github.com/nvim-treesitter/nvim-treesitter'}
})
require'image'.setup({
backend = "kitty",
integrations = {
markdown = {
@@ -13,7 +10,7 @@ return {
clear_in_insert_mode = false,
download_remote_images = true,
only_render_image_at_cursor = false,
filetypes = { "markdown", "vimwiki" }, -- markdown extensions (ie. quarto) can go here
filetypes = { "markdown", "vimwiki" },
},
neorg = {
enabled = true,
@@ -28,6 +25,4 @@ return {
max_width_window_percentage = nil,
max_height_window_percentage = 50,
kitty_method = "normal",
},
},
}
})

View File

@@ -0,0 +1,14 @@
require'plugins.avante'
require'plugins.barbar'
require'plugins.colors'
require'plugins.cloak'
require'plugins.image'
require'plugins.lsp'
require'plugins.lualine'
require'plugins.neotree'
require'plugins.nerdcommenter'
require'plugins.snacks'
require'plugins.telescope'
require'plugins.treesitter'
require'plugins.trouble'
require'plugins.undotree'

View File

@@ -1,20 +0,0 @@
return {
{
'kawre/leetcode.nvim',
build = ':TSUpdate html',
dependencies = {
'nvim-telescope/telescope.nvim',
'nvim-lua/plenary.nvim',
'MunifTanjim/nui.nvim',
'nvim-treesitter/nvim-treesitter',
'rcarriga/nvim-notify',
'nvim-tree/nvim-web-devicons',
'3rd/image.nvim',
},
opts = {
arg = "lc",
lang = "typescript",
image_support = false,
},
},
}

View File

@@ -1,111 +1,57 @@
local root_files = {
'.luarc.json',
'.luarc.jsonc',
'.luacheckrc',
'.stylua.toml',
'stylua.toml',
'selene.toml',
'selene.yml',
'.git',
}
return {
vim.pack.add({
{ src = 'https://github.com/mason-org/mason.nvim' },
{ src = 'https://github.com/neovim/nvim-lspconfig' },
{ src = 'https://github.com/mason-org/mason-lspconfig.nvim' },
{ src = 'https://github.com/hrsh7th/nvim-cmp' },
{ src = 'https://github.com/hrsh7th/cmp-nvim-lsp' },
{ src = 'https://github.com/nvim-lua/plenary.nvim' },
{ src = 'https://github.com/hrsh7th/cmp-nvim-lsp-document-symbol' },
{ src = 'https://github.com/hrsh7th/cmp-nvim-lua' },
{ src = 'https://github.com/hrsh7th/cmp-path' },
{ src = 'https://github.com/hrsh7th/cmp-buffer' },
{ src = 'https://github.com/hrsh7th/cmp-emoji' },
{ src = 'https://github.com/chrisgrieser/cmp-nerdfont' },
{ src = 'https://github.com/jcha0713/cmp-tw2css' },
{ src = 'https://github.com/SergioRibera/cmp-dotenv' },
{ src = 'https://github.com/saadparwaiz1/cmp_luasnip' },
{ src = 'https://github.com/onsails/lspkind.nvim' },
{ src = 'https://github.com/rafamadriz/friendly-snippets' },
{ src = 'https://github.com/j-hui/fidget.nvim' },
{ src = 'https://github.com/David-Kunz/cmp-npm' },
{ src = 'https://github.com/stevearc/conform.nvim' },
{
"neovim/nvim-lspconfig",
dependencies = {
"williamboman/mason.nvim",
"williamboman/mason-lspconfig.nvim",
"hrsh7th/nvim-cmp",
"hrsh7th/cmp-nvim-lsp",
'hrsh7th/cmp-nvim-lsp-document-symbol',
'hrsh7th/cmp-nvim-lua',
"hrsh7th/cmp-path",
"hrsh7th/cmp-buffer",
'hrsh7th/cmp-emoji',
'chrisgrieser/cmp-nerdfont',
'jcha0713/cmp-tw2css',
'SergioRibera/cmp-dotenv',
'saadparwaiz1/cmp_luasnip',
'onsails/lspkind.nvim',
'rafamadriz/friendly-snippets',
"j-hui/fidget.nvim",
{
"David-Kunz/cmp-npm",
dependencies = { 'nvim-lua/plenary.nvim' },
ft = "json",
config = function()
require('cmp-npm').setup({})
end
src = 'https://github.com/L3MON4D3/LuaSnip',
version = vim.version.range('2')
},
"stevearc/conform.nvim",
{
'L3MON4D3/LuaSnip',
version = 'v2.*',
build = 'make install_jsregexp',
},
{
'supermaven-inc/supermaven-nvim',
config = function()
require('supermaven-nvim').setup({
--keymaps = {
--accept_suggestion = '<Tab>',
--clear_suggestion = '<C-]>',
--accept_word = '<C-.>',
--},
disable_inline_completion = true, -- for cmp
{ src = 'https://github.com/supermaven-inc/supermaven-nvim' },
{ src = 'https://github.com/garyhurtz/cmp_kitty' },
{ src = 'https://github.com/windwp/nvim-autopairs' },
{ src = 'https://github.com/windwp/nvim-ts-autotag' },
--{ src = 'https://github.com/hrsh7th/cmp-cmdline' },
--{ src = 'https://github.com/chrisgrieser/cmp-yanky' },
})
end,
},
--{ 'hrsh7th/cmp-cmdline' },
--{ 'kbwo/cmp-yank' },
--{
--'garyhurtz/cmp_kitty',
--init = function()
--require('cmp_kitty'):setup()
--end
--},
},
config = function()
require("conform").setup({
formatters_by_ft = {
}
})
local cmp = require('cmp')
local cmp_lsp = require("cmp_nvim_lsp")
local cmp = require 'cmp'
local cmp_lsp = require 'cmp_nvim_lsp'
local lspconfig = require 'lspconfig'
local capabilities = vim.tbl_deep_extend(
"force",
'force',
{},
vim.lsp.protocol.make_client_capabilities(),
cmp_lsp.default_capabilities())
require("fidget").setup({})
require("mason").setup()
require("mason-lspconfig").setup({
ensure_installed = {
'bashls',
'docker_compose_language_service',
'dockerls',
'eslint',
'intelephense',
'jsonls',
'gopls',
'lua_ls',
'pyright',
'rust_analyzer',
'sqlls',
'tailwindcss',
'yamlls',
},
cmp_lsp.default_capabilities()
)
local cmp_select = { behavior = cmp.SelectBehavior.Select }
local lspkind = require 'lspkind'
local cmp_autopairs = require'nvim-autopairs.completion.cmp'
require 'mason'.setup({})
require 'mason-lspconfig'.setup({
handlers = {
function(server_name) -- default handler (optional)
require("lspconfig")[server_name].setup {
function(server_name)
require 'lspconfig'[server_name].setup({
capabilities = capabilities
}
})
end,
zls = function()
local lspconfig = require("lspconfig")
lspconfig.zls.setup({
root_dir = lspconfig.util.root_pattern(".git", "build.zig", "zls.json"),
settings = {
@@ -118,69 +64,66 @@ return {
})
vim.g.zig_fmt_parse_errors = 0
vim.g.zig_fmt_autosave = 0
end,
["lua_ls"] = function()
local lspconfig = require("lspconfig")
lspconfig.lua_ls.setup {
lspconfig.lua_ls.setup({
capabilities = capabilities,
settings = {
Lua = {
format = {
enable = true,
-- Put format options here
-- NOTE: the value should be STRING!!
defaultConfig = {
indent_style = "space",
indent_size = "2",
}
},
}
}
}
},
},
},
})
end,
}
})
local cmp_select = { behavior = cmp.SelectBehavior.Select }
cmp.setup.cmdline(':', {
mapping = cmp.mapping.preset.cmdline(),
sources = cmp.config.sources({
{ name = 'path' }
}, {
{
name = 'cmdline',
option = {
ignore_cmds = { 'Man', '!' }
}
}
})
})
local lspkind = require('lspkind')
cmp.setup({
snippet = {
expand = function(args)
require('luasnip').lsp_expand(args.body)
end,
},
window = {
completion = cmp.config.window.bordered(),
documentation = cmp.config.window.bordered(),
},
sources = {
{name = 'supermaven'},
{name = 'path'},
{name = 'buffer', keyword_length = 3},
{ name = 'nvim_lsp' },
{ name = 'luasnip' },
{ name = 'buffer' },
{ name = 'supermaven' },
--{ name = 'luasnip', keyword_length = 2 },
--{ name = 'buffer', keyword_length = 3 },
--{ name = 'supermaven', keyword_length = 2 },
{
name = 'path',
option = {
pathMappings = {
['@'] = '${folder}/src',
['/'] = '${folder}/src/public',
['/components'] = '${folder}/src/components',
},
trailing_slash = true,
},
},
{ name = 'nvim_lsp_document_symbol' },
{ name = 'nvim_lsp_signature_health' },
{ name = 'nvim_lua' },
{name = 'luasnip', keyword_length = 2},
{ name = 'nerdfont' },
{ name = 'emoji' },
{ name = 'npm' },
{ name = 'cmp-tw2css' },
{ name = 'dotenv' },
--{name = 'cmdline'},
--{name = 'kitty'},
--{name = 'yank'},
{ name = 'kitty' },
{ name = 'render-markdown' },
{ name = 'cmdline' },
--{ name = 'cmp_yanky' },
},
formatting = {
format = lspkind.cmp_format({
@@ -190,17 +133,16 @@ return {
abbr = 50,
},
symbol_map = {
Supermaven = "",
Supermaven = '',
},
ellipsis_char = '...',
show_labelDetails = true,
before = function(entry, vim_item)
return vim_item
end
})
end,
}),
},
mapping = cmp.mapping.preset.insert({
-- Tab to select the next item
['<Tab>'] = cmp.mapping(function(fallback)
if cmp.visible() then
if cmp.get_selected_entry() then
@@ -215,6 +157,8 @@ return {
['<C-y>'] = cmp.mapping.confirm({ select = true }),
['<C-Space>'] = cmp.mapping.complete(),
['<C-b>'] = cmp.mapping.scroll_docs(-4),
['<C-f>'] = cmp.mapping.scroll_docs(4),
['<C-e>'] = cmp.mapping.abort(),
['<C-p>'] = cmp.mapping.select_prev_item(cmp_select),
['<C-n>'] = cmp.mapping.select_next_item(cmp_select),
@@ -224,31 +168,84 @@ return {
preselect = cmp.PreselectMode.Item,
completion = {
completeopt = 'menu,menuone,noinsert',
}
},
})
cmp.event:on('confirm_done', cmp_autopairs.on_confirm_done())
require 'cmp_kitty':setup({})
require 'cmp-npm'.setup({})
require 'supermaven-nvim'.setup({
disable_inline_completion = true,
})
require 'conform'.setup({
formatters_by_ft = {
cs = { 'csharpier', 'lsp' },
javascript = { 'prettierd', 'prettier' },
javascriptreact = { 'prettierd', 'prettier' },
typescript = { 'prettierd', 'prettier' },
typescriptreact = { 'prettierd', 'prettier' },
json = { 'prettierd', 'prettier' },
html = { 'prettierd', 'prettier' },
css = { 'prettierd', 'prettier' },
lua = { 'stylua' },
},
})
require 'fidget'.setup({})
require 'nvim-autopairs'.setup({})
require 'nvim-ts-autotag'.setup({})
--cmp.setup.cmdline('/', {
--mapping = cmp.mapping.preset.cmdline(),
--sources = {
--{ name = 'buffer' }
--}
--})
--cmp.setup.cmdline(':', {
--mapping = cmp.mapping.preset.cmdline(),
--sources = cmp.config.sources({
--{ name = 'path' }
--}, {
--{
--name = 'cmdline',
--}
--})
--})
vim.lsp.enable({
'asm_lsp',
'bashls',
'cmake',
'cssls',
'css_variables',
'cssmodules_ls',
'docker_compose_language_service',
'dockerls',
'eslint',
'gopls',
'gradle_ls',
'graphql',
'html',
'htmx',
'intelephense',
'jsonls',
'kotlin_lsp',
'lua_ls',
'markdown_oxide',
'nginx_language_server',
'prismals',
'pyright',
'rust-analyzer',
'sqlls',
'svelte_language_server',
'tailwindcss',
'ts_ls',
'tinymist',
'yamlls',
})
vim.diagnostic.config({
-- update_in_insert = true,
float = {
focusable = false,
style = "minimal",
border = "rounded",
source = "always",
source = true,
header = "",
prefix = "",
},
})
end
},
{
'windwp/nvim-autopairs',
event = "InsertEnter",
config = true
},
{
'windwp/nvim-ts-autotag',
config = function ()
require('nvim-ts-autotag').setup()
end
},
}

View File

@@ -1,14 +1,12 @@
return {
{
'nvim-lualine/lualine.nvim',
dependencies = {
'nvim-tree/nvim-web-devicons',
'folke/tokyonight.nvim',
},
opts = {
vim.pack.add({
{ src = 'https://github.com/nvim-lualine/lualine.nvim' },
{ src = 'https://github.com/nvim-tree/nvim-web-devicons' },
{ src = 'https://github.com/folke/tokyonight.nvim' },
})
require'lualine'.setup({
options = {
icons_enabled = true,
theme = 'tokyonight',
theme = 'tokyonight-moon',
component_separators = { left = '', right = ''},
section_separators = { left = '', right = ''},
disabled_filetypes = {
@@ -23,7 +21,7 @@ return {
statusline = 1000,
tabline = 1000,
winbar = 1000,
refresh_time = 16, -- ~60fps
refresh_time = 16,
events = {
'WinEnter',
'BufEnter',
@@ -58,6 +56,4 @@ return {
winbar = {},
inactive_winbar = {},
extensions = {}
},
}
}
})

View File

@@ -1,67 +1,30 @@
return {
-- If you want neo-tree's file operations to work with LSP (updating imports, etc.), you can use a plugin like
-- https://github.com/antosha417/nvim-lsp-file-operations:
vim.pack.add({
{
"antosha417/nvim-lsp-file-operations",
dependencies = {
"nvim-lua/plenary.nvim",
"nvim-neo-tree/neo-tree.nvim",
src = 'https://github.com/nvim-neo-tree/neo-tree.nvim',
version = vim.version.range('3')
},
config = function()
require("lsp-file-operations").setup()
end,
'https://github.com/nvim-lua/plenary.nvim',
'https://github.com/MunifTanjim/nui.nvim',
'https://github.com/nvim-tree/nvim-web-devicons',
'https://github.com/antosha417/nvim-lsp-file-operations',
'https://github.com/3rd/image.nvim',
{
src = 'https://github.com/s1n7ax/nvim-window-picker',
version = vim.version.range('2'),
},
{
"nvim-neo-tree/neo-tree.nvim",
branch = "v3.x",
dependencies = {
"nvim-lua/plenary.nvim",
"nvim-tree/nvim-web-devicons", -- not strictly required, but recommended
"MunifTanjim/nui.nvim",
{"3rd/image.nvim", opts = {}}, -- Optional image support in preview window: See `# Preview Mode` for more information
{
"s1n7ax/nvim-window-picker", -- for open_with_window_picker keymaps
version = "2.*",
config = function()
require("window-picker").setup({
})
require('lsp-file-operations').setup()
require('window-picker').setup({
filter_rules = {
include_current_win = false,
autoselect_one = true,
-- filter using buffer options
bo = {
-- if the file type is one of following, the window will be ignored
filetype = { "neo-tree", "neo-tree-popup", "notify" },
-- if the buffer type is one of following, the window will be ignored
buftype = { "terminal", "quickfix" },
},
},
})
end,
},
},
keys = {
{
'<leader>t',
'<Cmd>Neotree toggle<CR>',
mode = { 'n', 'v' },
desc = 'Toggle neo-tree'
},
{
'<leader>T',
'<Cmd>Neotree focus<CR>',
mode = { 'n', 'v' },
desc = 'Focus neo-tree'
},
{ '<leader>h', '<C-w>h', mode = { 'n', 'v' }, desc = 'Left' },
{ '<leader>j', '<C-w>j', mode = { 'n', 'v' }, desc = 'Down' },
{ '<leader>k', '<C-w>k', mode = { 'n', 'v' }, desc = 'Up' },
{ '<leader>l', '<C-w>l', mode = { 'n', 'v' }, desc = 'Right' },
},
lazy = false,
-----Instead of using `config`, you can use `opts` instead, if you'd like:
---@module "neo-tree"
---@type neotree.Config
opts = {
require('neo-tree').setup({
vim.diagnostic.config({
signs = {
text = {
@@ -72,52 +35,37 @@ return {
},
}
}),
-- In older versions, you can define the signs manually:
-- vim.fn.sign_define("DiagnosticSignError", { text = " ", texthl = "DiagnosticSignError" })
-- vim.fn.sign_define("DiagnosticSignWarn", { text = " ", texthl = "DiagnosticSignWarn" })
-- vim.fn.sign_define("DiagnosticSignInfo", { text = " ", texthl = "DiagnosticSignInfo" })
-- vim.fn.sign_define("DiagnosticSignHint", { text = "󰌵", texthl = "DiagnosticSignHint" })
close_if_last_window = true, -- Close Neo-tree if it is the last window left in the tab
popup_border_style = "NC", -- or "" to use 'winborder' on Neovim v0.11+
close_if_last_window = true,
enable_git_status = true,
enable_diagnostics = true,
open_files_do_not_replace_types = { "terminal", "trouble", "qf" }, -- when opening files, do not use windows containing these filetypes or buftypes
open_files_do_not_replace_types = { 'terminal', 'trouble', 'qf' },
open_files_using_relative_paths = false,
sort_case_insensitive = true, -- used when sorting files and directories in the tree
sort_function = nil, -- use a custom function for sorting files and directories in the tree
--sort_function = function (a,b)
--if a.type == b.type then
--return a.path > b.path
--else
--return a.type > b.type
--end
--end, -- this sorts files and directories descendantly
sort_case_insensitive = true,
sort_function = nil,
default_component_configs = {
container = {
enable_character_fade = true,
},
indent = {
indent_size = 2,
padding = 1, -- extra padding on left hand side
-- indent guides
padding = 1,
with_markers = true,
indent_marker = "",
last_indent_marker = "",
highlight = "NeoTreeIndentMarker",
-- expander config, needed for nesting files
with_expanders = nil, -- if nil and file nesting is enabled, will enable expanders
expander_collapsed = "",
expander_expanded = "",
expander_highlight = "NeoTreeExpander",
indent_marker = '',
last_indent_marker = '',
highlight = 'NeoTreeIndentMarker',
with_expanders = nil,
expander_collapsed = '',
expander_expanded = '',
expander_highlight = 'NeoTreeExpander',
},
icon = {
folder_closed = "",
folder_open = "",
folder_empty = "󰜌",
provider = function(icon, node, state) -- default icon provider utilizes nvim-web-devicons if available
if node.type == "file" or node.type == "terminal" then
local success, web_devicons = pcall(require, "nvim-web-devicons")
local name = node.type == "terminal" and "terminal" or node.name
folder_closed = '',
folder_open = '',
folder_empty = '󰜌',
provider = function(icon, node, state)
if node.type == 'file' or node.type == 'terminal' then
local success, web_devicons = pcall(require, 'nvim-web-devicons')
local name = node.type == 'terminal' and 'terminal' or node.name
if success then
local devicon, hl = web_devicons.get_icon(name)
icon.text = devicon or icon.text
@@ -125,298 +73,243 @@ return {
end
end
end,
-- The next two settings are only a fallback, if you use nvim-web-devicons and configure default icons there
-- then these will never be used.
default = "*",
highlight = "NeoTreeFileIcon",
default = '*',
highlight = 'NeoTreeFileIcon',
},
modified = {
symbol = "[+]",
highlight = "NeoTreeModified",
symbol = '[+]',
highlight = 'NeoTreeModified',
},
name = {
trailing_slash = false,
use_git_status_colors = true,
highlight = "NeoTreeFileName",
highlight = 'NeoTreeFileName',
},
git_status = {
symbols = {
-- Change type
added = "", -- or "✚", but this is redundant info if you use git_status_colors on the name
modified = "", -- or "", but this is redundant info if you use git_status_colors on the name
deleted = "", -- this can only be used in the git_status source
renamed = "󰁕", -- this can only be used in the git_status source
-- Status type
untracked = "",
ignored = "",
unstaged = "󰄱",
staged = "",
conflict = "",
added = '',
modified = '',
deleted = '',
renamed = '󰁕',
untracked = '',
ignored = '',
unstaged = '󰄱',
staged = '',
conflict = '',
},
},
-- If you don't want to use these columns, you can set `enabled = false` for each of them individually
file_size = {
enabled = true,
width = 12, -- width of the column
required_width = 64, -- min width of window required to show this column
width = 12,
required_width = 64,
},
type = {
enabled = true,
width = 10, -- width of the column
required_width = 122, -- min width of window required to show this column
width = 10,
required_width = 122,
},
last_modified = {
enabled = true,
width = 20, -- width of the column
required_width = 88, -- min width of window required to show this column
width = 20,
required_width = 88,
},
created = {
enabled = true,
width = 20, -- width of the column
required_width = 110, -- min width of window required to show this column
width = 20,
required_width = 110,
},
symlink_target = {
enabled = false,
},
},
-- A list of functions, each representing a global custom command
-- that will be available in all sources (if not overridden in `opts[source_name].commands`)
-- see `:h neo-tree-custom-commands-global`
commands = {},
window = {
position = "left",
position = 'left',
width = 30,
mapping_options = {
noremap = true,
nowait = true,
},
mappings = {
["<space>"] = {
"toggle_node",
nowait = false, -- disable `nowait` if you have existing combos starting with this char that you want to use
['<space>'] = {
'toggle_node',
nowait = false,
},
["<2-LeftMouse>"] = "open",
["<cr>"] = "open",
["<esc>"] = "cancel", -- close preview or floating neo-tree window
["P"] = { "toggle_preview", config = { use_float = true, use_image_nvim = true } },
-- Read `# Preview Mode` for more information
["l"] = "focus_preview",
["S"] = "open_split",
["s"] = "open_vsplit",
-- ["S"] = "split_with_window_picker",
-- ["s"] = "vsplit_with_window_picker",
["t"] = "open_tabnew",
-- ["<cr>"] = "open_drop",
-- ["t"] = "open_tab_drop",
["w"] = "open_with_window_picker",
--["P"] = "toggle_preview", -- enter preview mode, which shows the current node without focusing
["C"] = "close_node",
-- ['C'] = 'close_all_subnodes',
["z"] = "close_all_nodes",
--["Z"] = "expand_all_nodes",
--["Z"] = "expand_all_subnodes",
["a"] = {
"add",
-- this command supports BASH style brace expansion ("x{a,b,c}" -> xa,xb,xc). see `:h neo-tree-file-actions` for details
-- some commands may take optional config options, see `:h neo-tree-mappings` for details
['<2-LeftMouse>'] = 'open',
['<cr>'] = 'open',
['<esc>'] = 'cancel',
['P'] = { 'toggle_preview', config = { use_float = true, use_image_nvim = true } },
['l'] = 'focus_preview',
['S'] = 'open_split',
['s'] = 'open_vsplit',
['t'] = 'open_tabnew',
['w'] = 'open_with_window_picker',
['C'] = 'close_node',
['z'] = 'close_all_nodes',
['a'] = {
'add',
config = {
show_path = "none", -- "none", "relative", "absolute"
show_path = 'relative',
},
},
["A"] = "add_directory", -- also accepts the optional config.show_path option like "add". this also supports BASH style brace expansion.
["d"] = "delete",
["r"] = "rename",
["b"] = "rename_basename",
["y"] = "copy_to_clipboard",
["x"] = "cut_to_clipboard",
["p"] = "paste_from_clipboard",
["c"] = "copy", -- takes text input for destination, also accepts the optional config.show_path option like "add":
-- ["c"] = {
-- "copy",
-- config = {
-- show_path = "none" -- "none", "relative", "absolute"
-- }
--}
["m"] = "move", -- takes text input for destination, also accepts the optional config.show_path option like "add".
["q"] = "close_window",
["R"] = "refresh",
["?"] = "show_help",
["<"] = "prev_source",
[">"] = "next_source",
["i"] = "show_file_details",
-- ["i"] = {
-- "show_file_details",
-- -- format strings of the timestamps shown for date created and last modified (see `:h os.date()`)
-- -- both options accept a string or a function that takes in the date in seconds and returns a string to display
-- -- config = {
-- -- created_format = "%Y-%m-%d %I:%M %p",
-- -- modified_format = "relative", -- equivalent to the line below
-- -- modified_format = function(seconds) return require('neo-tree.utils').relative_date(seconds) end
-- -- }
-- },
['A'] = 'add_directory',
['d'] = 'delete',
['r'] = 'rename',
['b'] = 'rename_basename',
['y'] = 'copy_to_clipboard',
['x'] = 'cut_to_clipboard',
['p'] = 'paste_from_clipboard',
['c'] = { 'copy', config = { show_path = 'relative' } },
['m'] = { 'move', config = { show_path = 'relative' } },
['q'] = 'close_window',
['R'] = 'refresh',
['?'] = 'show_help',
['<'] = 'prev_source',
['>'] = 'next_source',
['i'] = 'show_file_details',
},
},
nesting_rules = {},
filesystem = {
filtered_items = {
visible = false, -- when true, they will just be displayed differently than normal items
visible = false,
hide_dotfiles = true,
hide_gitignored = true,
hide_hidden = true, -- only works on Windows for hidden files/directories
hide_hidden = true,
hide_by_name = {
"node_modules",
".next",
".vscode",
".idea",
'node_modules',
'.next',
'.vscode',
'.idea',
},
hide_by_pattern = { -- uses glob style patterns
"*.meta",
"*/src/*/tsconfig.json",
hide_by_pattern = {
'*.meta',
'*/src/*/tsconfig.json',
},
always_show = { -- remains visible even if other settings would normally hide it
--".gitignored",
always_show = {
'.gitignored',
},
always_show_by_pattern = { -- uses glob style patterns
".env*",
'.env*',
},
never_show = { -- remains hidden even if visible is toggled to true, this overrides always_show
".DS_Store",
"thumbs.db"
},
never_show_by_pattern = { -- uses glob style patterns
--".null-ls_*",
never_show = {
'.DS_Store',
'thumbs.db'
},
never_show_by_pattern = {},
},
follow_current_file = {
enabled = false, -- This will find and focus the file in the active buffer every time
-- -- the current file is changed while the tree is open.
leave_dirs_open = false, -- `false` closes auto expanded dirs, such as with `:Neotree reveal`
enabled = false,
leave_dirs_open = false,
},
group_empty_dirs = false, -- when true, empty folders will be grouped together
hijack_netrw_behavior = "open_default", -- netrw disabled, opening a directory opens neo-tree
-- in whatever position is specified in window.position
-- "open_current", -- netrw disabled, opening a directory opens within the
-- window like netrw would, regardless of window.position
-- "disabled", -- netrw left alone, neo-tree does not handle opening dirs
use_libuv_file_watcher = false, -- This will use the OS level file watchers to detect changes
-- instead of relying on nvim autocmd events.
group_empty_dirs = false,
hijack_netrw_behavior = 'open_default',
use_libuv_file_watcher = false,
commands = {
avante_add_files = function(state)
local node = state.tree:get_node()
local filepath = node:get_id()
local relative_path = require('avante.utils').relative_path(filepath)
local sidebar = require('avante').get()
local open = sidebar:is_open()
-- ensure avante sidebar is open
if not open then
require('avante.api').ask()
sidebar = require('avante').get()
end
sidebar.file_selector:add_selected_file(relative_path)
-- remove neo tree buffer
if not open then
sidebar.file_selector:remove_selected_file('neo-tree filesystem [1]')
end
end,
},
window = {
mappings = {
["<bs>"] = "navigate_up",
["."] = "set_root",
["H"] = "toggle_hidden",
["/"] = "fuzzy_finder",
["D"] = "fuzzy_finder_directory",
["#"] = "fuzzy_sorter", -- fuzzy sorting using the fzy algorithm
-- ["D"] = "fuzzy_sorter_directory",
["f"] = "filter_on_submit",
["<c-x>"] = "clear_filter",
["[g"] = "prev_git_modified",
["]g"] = "next_git_modified",
["o"] = {
"show_help",
['<bs>'] = 'navigate_up',
['.'] = 'set_root',
['H'] = 'toggle_hidden',
['/'] = 'fuzzy_finder',
['D'] = 'fuzzy_finder_directory',
['#'] = 'fuzzy_sorter',
-- ['D'] = 'fuzzy_sorter_directory',
['f'] = 'filter_on_submit',
['<c-x>'] = 'clear_filter',
['[g'] = 'prev_git_modified',
[']g'] = 'next_git_modified',
['o'] = {
'show_help',
nowait = false,
config = { title = "Order by", prefix_key = "o" },
config = { title = 'Order by', prefix_key = 'o' },
},
['oa'] = 'avante_add_files',
["oc"] = { "order_by_created", nowait = false },
["od"] = { "order_by_diagnostics", nowait = false },
["og"] = { "order_by_git_status", nowait = false },
["om"] = { "order_by_modified", nowait = false },
["on"] = { "order_by_name", nowait = false },
["os"] = { "order_by_size", nowait = false },
["ot"] = { "order_by_type", nowait = false },
-- ['<key>'] = function(state) ... end,
['oc'] = { 'order_by_created', nowait = false },
['od'] = { 'order_by_diagnostics', nowait = false },
['og'] = { 'order_by_git_status', nowait = false },
['om'] = { 'order_by_modified', nowait = false },
['on'] = { 'order_by_name', nowait = false },
['os'] = { 'order_by_size', nowait = false },
['ot'] = { 'order_by_type', nowait = false },
},
fuzzy_finder_mappings = { -- define keymaps for filter popup window in fuzzy_finder_mode
["<down>"] = "move_cursor_down",
["<C-n>"] = "move_cursor_down",
["<up>"] = "move_cursor_up",
["<C-p>"] = "move_cursor_up",
["<esc>"] = "close",
-- ['<key>'] = function(state, scroll_padding) ... end,
fuzzy_finder_mappings = {
['<down>'] = 'move_cursor_down',
['<C-n>'] = 'move_cursor_down',
['<up>'] = 'move_cursor_up',
['<C-p>'] = 'move_cursor_up',
['<esc>'] = 'close',
},
},
},
buffers = {
follow_current_file = {
enabled = true, -- This will find and focus the file in the active buffer every time
-- -- the current file is changed while the tree is open.
leave_dirs_open = false, -- `false` closes auto expanded dirs, such as with `:Neotree reveal`
enabled = true,
leave_dirs_open = false,
},
group_empty_dirs = true, -- when true, empty folders will be grouped together
group_empty_dirs = true,
show_unloaded = true,
window = {
mappings = {
["d"] = "buffer_delete",
["bd"] = "buffer_delete",
["<bs>"] = "navigate_up",
["."] = "set_root",
["o"] = {
"show_help",
['d'] = 'buffer_delete',
['bd'] = 'buffer_delete',
['<bs>'] = 'navigate_up',
['.'] = 'set_root',
['o'] = {
'show_help',
nowait = false,
config = { title = "Order by", prefix_key = "o" },
config = { title = 'Order by', prefix_key = 'o' },
},
["oc"] = { "order_by_created", nowait = false },
["od"] = { "order_by_diagnostics", nowait = false },
["om"] = { "order_by_modified", nowait = false },
["on"] = { "order_by_name", nowait = false },
["os"] = { "order_by_size", nowait = false },
["ot"] = { "order_by_type", nowait = false },
['oc'] = { 'order_by_created', nowait = false },
['od'] = { 'order_by_diagnostics', nowait = false },
['om'] = { 'order_by_modified', nowait = false },
['on'] = { 'order_by_name', nowait = false },
['os'] = { 'order_by_size', nowait = false },
['ot'] = { 'order_by_type', nowait = false },
},
},
},
git_status = {
window = {
position = "float",
position = 'float',
mappings = {
["A"] = "git_add_all",
["gu"] = "git_unstage_file",
["gU"] = "git_undo_last_commit",
["ga"] = "git_add_file",
["gr"] = "git_revert_file",
["gc"] = "git_commit",
["gp"] = "git_push",
["gg"] = "git_commit_and_push",
["o"] = {
"show_help",
['A'] = 'git_add_all',
['gu'] = 'git_unstage_file',
['gU'] = 'git_undo_last_commit',
['ga'] = 'git_add_file',
['gr'] = 'git_revert_file',
['gc'] = 'git_commit',
['gp'] = 'git_push',
['gg'] = 'git_commit_and_push',
['o'] = {
'show_help',
nowait = false,
config = { title = "Order by", prefix_key = "o" },
config = { title = 'Order by', prefix_key = 'o' },
},
["oc"] = { "order_by_created", nowait = false },
["od"] = { "order_by_diagnostics", nowait = false },
["om"] = { "order_by_modified", nowait = false },
["on"] = { "order_by_name", nowait = false },
["os"] = { "order_by_size", nowait = false },
["ot"] = { "order_by_type", nowait = false },
['oc'] = { 'order_by_created', nowait = false },
['od'] = { 'order_by_diagnostics', nowait = false },
['om'] = { 'order_by_modified', nowait = false },
['on'] = { 'order_by_name', nowait = false },
['os'] = { 'order_by_size', nowait = false },
['ot'] = { 'order_by_type', nowait = false },
},
},
},
},
},
}
})
-- Neotree
vim.keymap.set({'n', 'v', 'x' }, '<leader>t', ':Neotree toggle<CR>')
vim.keymap.set({'n', 'v', 'x' }, '<leader>T', ':Neotree focus<CR>')

View File

@@ -1,13 +1,4 @@
return {
{
'scrooloose/nerdcommenter',
keys = {
{
'<leader>c',
'<plug>NERDCommenterToggle',
mode = { 'n', 'v' },
desc = 'Toggle comment'
}
}
},
}
vim.pack.add({
{ src = 'https://github.com/preservim/nerdcommenter' }
})
vim.keymap.set({ 'n', 'v', 'x'}, '<leader>c', '<plug>NERDCommenterToggle')

View File

@@ -1,12 +0,0 @@
return {
{
"rest-nvim/rest.nvim",
dependencies = {
"nvim-treesitter/nvim-treesitter",
opts = function (_, opts)
opts.ensure_installed = opts.ensure_installed or {}
table.insert(opts.ensure_installed, "http")
end,
}
},
}

View File

@@ -0,0 +1,11 @@
vim.pack.add({
{ src = 'https://github.com/folke/snacks.nvim' },
{ src = 'https://github.com/echasnovski/mini.icons' },
})
require'snacks'.setup({
animate = { enabled = true },
bigfile = { enabled = true },
image = { enabled = true },
indent = { enabled = true },
scroll = { enabled = true },
})

View File

@@ -1,31 +1,31 @@
local builtin = require('telescope.builtin')
return {
vim.pack.add({
{
'nvim-telescope/telescope.nvim',
tag = '0.1.8',
dependencies = { 'nvim-lua/plenary.nvim' },
cmd = 'Telescope',
opts = {
src = 'https://github.com/nvim-telescope/telescope.nvim',
version = vim.version.range('0.1'),
},
{ src = 'https://github.com/nvim-lua/plenary.nvim' },
})
require'telescope'.setup({
defaults = {
file_ignore_patterns = {"node_modules", ".git", ".cache", ".DS_Store", "Steam", "Media", "Pictures", "Downloads", "Videos", "Music", ".venv", ".conda", "School"},
file_ignore_patterns = {
'node_modules',
'.git',
'.next',
'.cache',
'.DS_Store',
'.venv',
'.conda',
},
},
keys = {
{
'<leader>ff', builtin.find_files, mode = { 'n'}, desc = 'Find files'
},
{
'<leader>fg', builtin.git_files, mode = { 'n'}, desc = 'Find files'
},
{
})
local builtin = require'telescope.builtin'
vim.keymap.set('n', '<leader>ff', builtin.find_files, { desc = 'Find files' })
vim.keymap.set('n', '<leader>fg', builtin.git_files, { desc = 'Find git files' })
vim.keymap.set(
'n',
'<leader>fs',
function()
builtin.grep_string({ search = vim.fn.input("Grep > ") })
builtin.grep_string({ search = vim.fn.input('Grep > ')})
end,
mode = { 'n'},
desc = 'Find files'
},
},
},
}
{ desc = 'Find string' }
)

View File

@@ -1,55 +0,0 @@
return {
{
"folke/tokyonight.nvim",
lazy = false,
priority = 1000,
opts = {
style = "moon", -- The theme comes in three styles, `storm`, a darker variant `night` and `day`
light_style = "night", -- The theme is used when the background is set to light
transparent = true, -- Enable this to disable setting the background color
terminal_colors = true, -- Configure the colors used when opening a `:terminal` in Neovim
styles = {
comments = { italic = true },
keywords = { italic = true },
functions = {},
variables = {},
-- Background styles. Can be "dark", "transparent" or "normal"
sidebars = "dark", -- style for sidebars, see below
floats = "dark", -- style for floating windows
},
day_brightness = 0.3, -- Adjusts the brightness of the colors of the **Day** style. Number between 0 and 1, from dull to vibrant colors
dim_inactive = false, -- dims inactive windows
lualine_bold = true, -- When `true`, section headers in the lualine theme will be bold
--- You can override specific color groups to use other groups or a hex color
--- function will be called with a ColorScheme table
---@param colors ColorScheme
on_colors = function(colors)
colors.comment = "#a0a7c5"
colors.terminal_black = "#828bb8"
end,
--- You can override specific highlights to use other groups or a hex color
--- function will be called with a Highlights and ColorScheme table
---@param highlights tokyonight.Highlights
---@param colors ColorScheme
on_highlights = function(highlights, colors) end,
cache = true, -- When set to true, the theme will be cached for better performance
---@type table<string, boolean|{enabled:boolean}>
plugins = {
-- enable all plugins when not using lazy.nvim
-- set to false to manually enable/disable plugins
all = package.loaded.lazy == nil,
-- uses your plugin manager to automatically enable needed plugins
-- currently only lazy.nvim is supported
auto = true,
-- add any plugins here that you want to enable
-- for all possible plugins, see:
-- * https://github.com/folke/tokyonight.nvim/tree/main/lua/tokyonight/groups
telescope = true,
},
},
},
}

View File

@@ -1,10 +1,12 @@
return {
vim.pack.add({
{
'nvim-treesitter/nvim-treesitter',
branch = 'master',
lazy = false,
build = ':TSUpdate',
config = function()
src = 'https://github.com/nvim-treesitter/nvim-treesitter',
version = 'master'
},
{ src = 'https://github.com/nvim-treesitter/playground' },
{ src = 'https://github.com/nvim-treesitter/nvim-treesitter-context' },
})
require'nvim-treesitter.install'.update({ with_sync = true })()
require'nvim-treesitter.configs'.setup({
ensure_installed = {
'bash',
@@ -63,47 +65,20 @@ return {
return true
end
end,
-- Setting this to true will run `:h syntax` and tree-sitter at the same time.
-- Set this to `true` if you depend on 'syntax' being enabled (like for indentation).
-- Using this option may slow down your editor, and you may see some duplicate highlights.
-- Instead of true it can also be a list of languages
additional_vim_regex_highlighting = false,
},
})
local treesitter_parser_config = require("nvim-treesitter.parsers").get_parser_configs()
treesitter_parser_config.templ = {
install_info = {
url = "https://github.com/vrischmann/tree-sitter-templ.git",
files = {"src/parser.c", "src/scanner.c"},
branch = "master",
},
}
vim.treesitter.language.register("templ", "templ")
end
},
{
'nvim-treesitter/playground',
},
{
"nvim-treesitter/nvim-treesitter-context",
after = "nvim-treesitter",
config = function()
require'treesitter-context'.setup{
enable = true, -- Enable this plugin (Can be enabled/disabled later via commands)
multiwindow = false, -- Enable multiwindow support.
max_lines = 0, -- How many lines the window should span. Values <= 0 mean no limit.
min_window_height = 0, -- Minimum editor window height to enable context. Values <= 0 mean no limit.
line_numbers = true,
multiline_threshold = 20, -- Maximum number of lines to show for a single context
trim_scope = 'outer', -- Which context lines to discard if `max_lines` is exceeded. Choices: 'inner', 'outer'
mode = 'cursor', -- Line used to calculate context. Choices: 'cursor', 'topline'
-- Separator between context and content. Should be a single character string, like '-'.
-- When separator is set, the context will only show up when there are at least 2 lines above cursorline.
separator = nil,
zindex = 20, -- The Z-index of the context window
on_attach = nil, -- (fun(buf: integer): boolean) return false to disable attaching
}
end
},
}
require'treesitter-context'.setup{
enable = true,
multiwindow = false,
max_lines = 10,
min_window_height = 0,
line_numbers = true,
multiline_threshold = 20,
trim_scope = 'outer',
mode = 'topline',
separator = nil,
zindex = 20,
on_attach = nil,
}

View File

@@ -1,39 +1,7 @@
return {
{
"folke/trouble.nvim",
opts = {},
cmd = "Trouble",
keys = {
{
"<leader>xx",
"<cmd>Trouble diagnostics toggle<cr>",
desc = "Diagnostics (Trouble)",
},
{
"<leader>xX",
"<cmd>Trouble diagnostics toggle filter.buf=0<cr>",
desc = "Buffer Diagnostics (Trouble)",
},
{
"<leader>xcs",
"<cmd>Trouble symbols toggle focus=false<cr>",
desc = "Symbols (Trouble)",
},
{
"<leader>xcl",
"<cmd>Trouble lsp toggle focus=false win.position=right<cr>",
desc = "LSP Definitions / references / ... (Trouble)",
},
{
"<leader>xL",
"<cmd>Trouble loclist toggle<cr>",
desc = "Location List (Trouble)",
},
{
"<leader>xQ",
"<cmd>Trouble qflist toggle<cr>",
desc = "Quickfix List (Trouble)",
},
},
},
}
vim.pack.add({
{ src = 'https://github.com/folke/trouble.nvim.git' },
})
vim.api.nvim_create_user_command('Trouble', function()
require("trouble").open()
end, { desc = "Open Trouble" })
vim.keymap.set({'n'}, '<leader>x', ':Trouble diagnostics toggle')

View File

@@ -1,13 +1,4 @@
return {
{
'mbbill/undotree',
keys = {
{
'<leader>u',
vim.cmd.UndotreeToggle,
mode = 'n',
desc = 'UndoTree'
},
},
},
}
vim.pack.add({
{ src = 'https://github.com/mbbill/undotree' },
})
vim.keymap.set({'n'}, '<leader>u', ':UndotreeToggle<CR>')

View File

@@ -23,6 +23,8 @@ alias docker-down='sudo docker compose down'
alias docker-stop='sudo docker compose stop'
alias docker-update='sudo docker compose down && sudo docker compose up -d'
alias docker-restart='sudo docker compose restart'
alias fprint-on='sudo authselect enable-feature with-fingerprint'
alias fprint-off='sudo authselect disable-feature with-fingerprint'
# File system

286
themes/openbar Normal file
View File

@@ -0,0 +1,286 @@
[/]
accent-color=['0.510', '0.667', '1.000']
accent-override=false
apply-accent-shell=true
apply-all-shell=true
apply-flatpak=false
apply-gtk=false
apply-menu-notif=true
apply-menu-shell=true
auto-bgalpha=false
autofg-bar=false
autofg-menu=true
autohg-bar=false
autohg-menu=true
autotheme-dark='Dark'
autotheme-font=false
autotheme-light='Light'
autotheme-refresh=false
balpha=0.12
bartype='Floating'
bcolor=['0.510', '0.667', '1.000']
bg-change=false
bgalpha=0.0
bgalpha-wmax=0.0
bgalpha2=0.0
bgcolor=['0.180', '0.184', '0.239']
bgcolor-wmax=['0.118', '0.118', '0.118']
bgcolor2=['0.247', '0.220', '0.251']
bgpalette=true
bguri='file:///home/gib/.local/share/backgrounds/2025-08-04-13-42-53-faroe_islands.jpg'
border-wmax=false
bordertype='solid'
bottom-margin=0.0
boxalpha=0.0
boxcolor=['0.180', '0.184', '0.239']
bradius=50.0
buttonbg-wmax=false
bwidth=0.5
candy1=['0', '0.61', '0.74']
candy10=['0.09', '0.19', '0.72']
candy11=['0.75', '0.49', '0.44']
candy12=['1', '0.92', '0.12']
candy13=['0.38', '0.63', '0.92']
candy14=['0.37', '0.36', '0.39']
candy15=['0.40', '0.23', '0.72']
candy16=['1', '0.32', '0.32']
candy2=['1', '0.41', '0.41']
candy3=['0.63', '0.16', '0.8']
candy4=['0.94', '0.60', '0.23']
candy5=['0.03', '0.41', '0.62']
candy6=['0.56', '0.18', '0.43']
candy7=['0.95', '0.12', '0.67']
candy8=['0.18', '0.76', '0.49']
candy9=['0.93', '0.20', '0.23']
candyalpha=0.0
candybar=false
card-hint=6
color-scheme='prefer-dark'
corner-radius=false
count1=384385
count10=289
count11=128
count12=7
count2=52561
count3=42265
count4=40816
count5=24718
count6=23775
count7=20816
count8=16249
count9=4991
cust-margin-wmax=true
dark-accent-color=['0.510', '0.667', '1.000']
dark-bcolor=['0.510', '0.667', '1.000']
dark-bgcolor=['0.180', '0.184', '0.239']
dark-bgcolor-wmax=['0.118', '0.118', '0.118']
dark-bgcolor2=['0.247', '0.220', '0.251']
dark-bguri='file:///home/gib/.local/share/backgrounds/2025-08-04-13-42-53-faroe_islands.jpg'
dark-boxcolor=['0.180', '0.184', '0.239']
dark-candy1=['0', '0.61', '0.74']
dark-candy10=['0.09', '0.19', '0.72']
dark-candy11=['0.75', '0.49', '0.44']
dark-candy12=['1', '0.92', '0.12']
dark-candy13=['0.38', '0.63', '0.92']
dark-candy14=['0.37', '0.36', '0.39']
dark-candy15=['0.40', '0.23', '0.72']
dark-candy16=['1', '0.32', '0.32']
dark-candy2=['1', '0.41', '0.41']
dark-candy3=['0.63', '0.16', '0.8']
dark-candy4=['0.94', '0.60', '0.23']
dark-candy5=['0.03', '0.41', '0.62']
dark-candy6=['0.56', '0.18', '0.43']
dark-candy7=['0.95', '0.12', '0.67']
dark-candy8=['0.18', '0.76', '0.49']
dark-candy9=['0.93', '0.20', '0.23']
dark-dbgcolor=['0.180', '0.184', '0.239']
dark-fgcolor=['1.0', '1.0', '1.0']
dark-hcolor=['0.510', '0.667', '1.000']
dark-hscd-color=['0.510', '0.667', '1.000']
dark-iscolor=['0.043', '0.086', '0.114']
dark-mbcolor=['0.180', '0.184', '0.239']
dark-mbgcolor=['0.180', '0.184', '0.239']
dark-mfgcolor=['1.0', '1.0', '1.0']
dark-mhcolor=['0.510', '0.667', '1.000']
dark-mscolor=['0.510', '0.667', '1.000']
dark-mshcolor=['0.180', '0.184', '0.239']
dark-palette1=['25', '42', '62']
dark-palette10=['148', '100', '104']
dark-palette11=['151', '108', '100']
dark-palette12=['121', '124', '144']
dark-palette2=['224', '173', '139']
dark-palette3=['111', '96', '112']
dark-palette4=['53', '73', '103']
dark-palette5=['70', '86', '113']
dark-palette6=['46', '68', '91']
dark-palette7=['67', '68', '88']
dark-palette8=['13', '27', '35']
dark-palette9=['107', '106', '132']
dark-shcolor=['0.000', '0.000', '0.000']
dark-smbgcolor=['0.128', '0.132', '0.193']
dark-vw-color=['0.510', '0.667', '1.000']
dark-winbcolor=['0.510', '0.667', '1.000']
dashdock-style='Default'
dbgalpha=0.84999999999999998
dbgcolor=['0.180', '0.184', '0.239']
dborder=false
dbradius=100.0
default-font='Sans 12'
destruct-color=['0.75', '0.11', '0.16']
disize=16.0
dshadow=true
fgalpha=1.0
fgcolor=['1.0', '1.0', '1.0']
fitts-widgets=false
font=''
gradient=false
gradient-direction='vertical'
gtk-popover=false
gtk-shadow='Default'
gtk-transparency=1.0
halpha=0.25
handle-border=20.0
hbar-gtk3only=false
hcolor=['0.510', '0.667', '1.000']
headerbar-hint=0
heffect=false
height=36.0
hpad=0.0
hscd-color=['0.510', '0.667', '1.000']
import-export=true
isalpha=0.0
iscolor=['0.043', '0.086', '0.114']
light-accent-color=['0', '0.75', '0.75']
light-bcolor=['0.051', '0.106', '0.137']
light-bgcolor=['0.835', '0.839', '0.863']
light-bgcolor-wmax=['0.922', '0.922', '0.922']
light-bgcolor2=['0.722', '0.753', '0.800']
light-bguri='file:///home/gib/.local/share/backgrounds/2025-08-04-13-42-53-faroe_islands.jpg'
light-boxcolor=['0.835', '0.839', '0.863']
light-candy1=['0', '0.61', '0.74']
light-candy10=['0.09', '0.19', '0.72']
light-candy11=['0.75', '0.49', '0.44']
light-candy12=['1', '0.92', '0.12']
light-candy13=['0.38', '0.63', '0.92']
light-candy14=['0.37', '0.36', '0.39']
light-candy15=['0.40', '0.23', '0.72']
light-candy16=['1', '0.32', '0.32']
light-candy2=['1', '0.41', '0.41']
light-candy3=['0.63', '0.16', '0.8']
light-candy4=['0.94', '0.60', '0.23']
light-candy5=['0.03', '0.41', '0.62']
light-candy6=['0.56', '0.18', '0.43']
light-candy7=['0.95', '0.12', '0.67']
light-candy8=['0.18', '0.76', '0.49']
light-candy9=['0.93', '0.20', '0.23']
light-dbgcolor=['0.125', '0.125', '0.125']
light-fgcolor=['1.0', '1.0', '1.0']
light-hcolor=['0.098', '0.165', '0.243']
light-hscd-color=['0.894', '0.659', '0.502']
light-iscolor=['0.835', '0.839', '0.863']
light-mbcolor=['0.098', '0.165', '0.243']
light-mbgcolor=['0.922', '0.906', '0.922']
light-mfgcolor=['1.0', '1.0', '1.0']
light-mhcolor=['0.098', '0.165', '0.243']
light-mscolor=['0.894', '0.659', '0.502']
light-mshcolor=['0.000', '0.000', '0.000']
light-palette1=['25', '42', '62']
light-palette10=['148', '100', '104']
light-palette11=['151', '108', '100']
light-palette12=['121', '124', '144']
light-palette2=['224', '173', '139']
light-palette3=['111', '96', '112']
light-palette4=['53', '73', '103']
light-palette5=['70', '86', '113']
light-palette6=['46', '68', '91']
light-palette7=['67', '68', '88']
light-palette8=['13', '27', '35']
light-palette9=['107', '106', '132']
light-shcolor=['0.000', '0.000', '0.000']
light-smbgcolor=['0.722', '0.753', '0.800']
light-vw-color=['0.894', '0.659', '0.502']
light-winbcolor=['0.894', '0.659', '0.502']
margin=1.0
margin-wmax=0.0
mbalpha=0.0
mbcolor=['0.180', '0.184', '0.239']
mbg-gradient=false
mbgalpha=0.92000000000000004
mbgcolor=['0.180', '0.184', '0.239']
menu-radius=30.0
menustyle=true
mfgalpha=1.0
mfgcolor=['1.0', '1.0', '1.0']
mhalpha=0.25
mhcolor=['0.510', '0.667', '1.000']
monitor-height=960
monitor-width=1440
monitors='all'
msalpha=0.80000000000000004
mscolor=['0.510', '0.667', '1.000']
mshalpha=1.0
mshcolor=['0.180', '0.184', '0.239']
neon=false
neon-wmax=false
notif-radius=20.0
palette1=['25', '42', '62']
palette10=['148', '100', '104']
palette11=['151', '108', '100']
palette12=['121', '124', '144']
palette2=['224', '173', '139']
palette3=['111', '96', '112']
palette4=['53', '73', '103']
palette5=['70', '86', '113']
palette6=['46', '68', '91']
palette7=['67', '68', '88']
palette8=['13', '27', '35']
palette9=['107', '106', '132']
pause-reload=false
position='Top'
prominent1=['100', '100', '100']
prominent2=['100', '100', '100']
prominent3=['100', '100', '100']
prominent4=['100', '100', '100']
prominent5=['100', '100', '100']
prominent6=['100', '100', '100']
qtoggle-radius=50.0
radius-bottomleft=true
radius-bottomright=true
radius-topleft=true
radius-topright=true
reloadstyle=true
removestyle=false
sbar-gradient='none'
set-bottom-margin=true
set-fullscreen=false
set-notif-position=true
set-notifications=false
set-overview=false
set-yarutheme=false
shadow=false
shalpha=0.0
shcolor=['0.000', '0.000', '0.000']
sidebar-hint=0
slider-height=20.0
smbgalpha=0.94999999999999996
smbgcolor=['0.128', '0.132', '0.193']
smbgoverride=true
success-color=['0.15', '0.635', '0.41']
traffic-light=false
trigger-autotheme=true
trigger-reload=true
view-hint=0
vpad=2.5
vw-color=['0.510', '0.667', '1.000']
warning-color=['0.96', '0.83', '0.17']
width-bottom=true
width-left=true
width-right=true
width-top=true
winbalpha=0.75
winbcolor=['0.510', '0.667', '1.000']
winbradius=15.0
winbwidth=0.0
window-hint=0
wmax-hbarhint=false
wmaxbar=true