summaryrefslogtreecommitdiff
path: root/.config/nvim
diff options
context:
space:
mode:
authorTom Li Dobnik <tomlidobnik1@gmail.com>2026-03-03 18:46:16 +0100
committerTom Li Dobnik <tomlidobnik1@gmail.com>2026-03-03 18:46:16 +0100
commitf7bbc5e6740f6199d7ed0fe704daaa7efd98c093 (patch)
treed6cd8984dbf2a8a909f16dde865a19a343c31d48 /.config/nvim
parent1f156148fadab8468a46e598296b18b54f7860ce (diff)
nvim update
Diffstat (limited to '.config/nvim')
-rw-r--r--.config/nvim/.editorconfig3
-rw-r--r--.config/nvim/.luarc.json10
-rw-r--r--.config/nvim/init.lua1141
-rw-r--r--.config/nvim/lazy-lock.json46
-rw-r--r--.config/nvim/lua/autocmds.lua28
-rw-r--r--.config/nvim/lua/config/lazy.lua36
-rw-r--r--.config/nvim/lua/config/plugins/blink-cmp.lua125
-rw-r--r--.config/nvim/lua/config/plugins/colorscheme.lua14
-rw-r--r--.config/nvim/lua/config/plugins/conform.lua40
-rw-r--r--.config/nvim/lua/config/plugins/flash.lua18
-rw-r--r--.config/nvim/lua/config/plugins/fzflua.lua29
-rw-r--r--.config/nvim/lua/config/plugins/gitsigns.lua36
-rw-r--r--.config/nvim/lua/config/plugins/leetcode.lua22
-rw-r--r--.config/nvim/lua/config/plugins/lsp.lua240
-rw-r--r--.config/nvim/lua/config/plugins/lualine.lua218
-rw-r--r--.config/nvim/lua/config/plugins/luasnip.lua21
-rw-r--r--.config/nvim/lua/config/plugins/markdown.lua220
-rw-r--r--.config/nvim/lua/config/plugins/mini.lua27
-rw-r--r--.config/nvim/lua/config/plugins/neotree.lua17
-rw-r--r--.config/nvim/lua/config/plugins/oil.lua37
-rw-r--r--.config/nvim/lua/config/plugins/rustacean.lua29
-rw-r--r--.config/nvim/lua/config/plugins/snacks.lua84
-rw-r--r--.config/nvim/lua/config/plugins/treesitter.lua43
-rw-r--r--.config/nvim/lua/config/plugins/typst.lua9
-rw-r--r--.config/nvim/lua/config/plugins/utils.lua58
-rw-r--r--.config/nvim/lua/config/plugins/uv.lua7
-rw-r--r--.config/nvim/lua/config/plugins/which-key.lua27
-rw-r--r--.config/nvim/lua/config/snippets/all.lua10
-rw-r--r--.config/nvim/lua/mappings.lua71
-rw-r--r--.config/nvim/lua/options.lua36
-rw-r--r--.config/nvim/nvim-macos.tar.gz1
-rw-r--r--.config/nvim/nvim-pack-lock.json85
32 files changed, 1222 insertions, 1566 deletions
diff --git a/.config/nvim/.editorconfig b/.config/nvim/.editorconfig
deleted file mode 100644
index 9a6cc75..0000000
--- a/.config/nvim/.editorconfig
+++ /dev/null
@@ -1,3 +0,0 @@
-[*.lua]
-indent_style = space
-indent_size = 2
diff --git a/.config/nvim/.luarc.json b/.config/nvim/.luarc.json
deleted file mode 100644
index 59e3c38..0000000
--- a/.config/nvim/.luarc.json
+++ /dev/null
@@ -1,10 +0,0 @@
-{
- "diagnostics.globals": [
- "MiniFiles",
- "Snacks",
- "MiniSplitjoin",
- "hipatterns",
- "MiniDiff",
- "vim"
- ]
-} \ No newline at end of file
diff --git a/.config/nvim/init.lua b/.config/nvim/init.lua
index 75ae3e9..fb59850 100644
--- a/.config/nvim/init.lua
+++ b/.config/nvim/init.lua
@@ -1,5 +1,1136 @@
-vim.g.bullets_enable_in_empty_buffers = 0
-require("config.lazy")
-require("options")
-require("mappings")
-require("autocmds")
+_G._startup_time = vim.loop.hrtime()
+-- ============================================================================
+-- OPTIONS
+-- ============================================================================
+vim.opt.termguicolors = true
+vim.opt.number = true -- line number
+vim.opt.relativenumber = true -- relative line numbers
+vim.opt.cursorline = true -- highlight current line
+vim.opt.wrap = false -- do not wrap lines by default
+vim.opt.scrolloff = 8 -- keep 8 lines above/below cursor
+vim.opt.sidescrolloff = 8 -- keep 8 lines to left/right of cursor
+
+vim.opt.tabstop = 4 -- tabwidth
+vim.opt.shiftwidth = 4 -- indent width
+vim.opt.softtabstop = 4 -- soft tab stop not tabs on tab/backspace
+vim.opt.expandtab = true -- use spaces instead of tabs
+vim.opt.smartindent = true -- smart auto-indent
+vim.opt.autoindent = true -- copy indent from current line
+
+vim.opt.ignorecase = true -- case insensitive search
+vim.opt.smartcase = true -- case sensitive if uppercase in string
+vim.opt.hlsearch = true -- highlight search matches
+vim.opt.incsearch = true -- show matches as you type
+
+vim.opt.signcolumn = "yes" -- always show a sign column
+vim.opt.showmatch = true -- highlights matching brackets
+vim.opt.cmdheight = 1 -- single line command line
+vim.opt.completeopt = "menuone,noinsert,noselect" -- completion options
+vim.opt.showmode = false -- do not show the mode, instead have it in statusline
+vim.opt.pumheight = 10 -- popup menu height
+vim.opt.pumblend = 10 -- popup menu transparency
+vim.opt.winblend = 0 -- floating window transparency
+vim.opt.conceallevel = 0 -- do not hide markup
+vim.opt.concealcursor = "" -- do not hide cursorline in markup
+vim.opt.lazyredraw = true -- do not redraw during macros
+vim.opt.synmaxcol = 300 -- syntax highlighting limit
+vim.opt.fillchars = { eob = " " } -- hide "~" on empty lines
+
+local undodir = vim.fn.expand("~/.vim/undodir")
+if
+ vim.fn.isdirectory(undodir) == 0 -- create undodir if nonexistent
+then
+ vim.fn.mkdir(undodir, "p")
+end
+
+vim.opt.backup = false -- do not create a backup file
+vim.opt.writebackup = false -- do not write to a backup file
+vim.opt.swapfile = false -- do not create a swapfile
+vim.opt.undofile = true -- do create an undo file
+vim.opt.undodir = undodir -- set the undo directory
+vim.opt.updatetime = 300 -- faster completion
+vim.opt.timeoutlen = 500 -- timeout duration
+vim.opt.ttimeoutlen = 0 -- key code timeout
+vim.opt.autoread = true -- auto-reload changes if outside of neovim
+vim.opt.autowrite = false -- do not auto-save
+
+vim.opt.hidden = true -- allow hidden buffers
+vim.opt.errorbells = false -- no error sounds
+vim.opt.backspace = "indent,eol,start" -- better backspace behaviour
+vim.opt.autochdir = false -- do not autochange directories
+vim.opt.iskeyword:append("-") -- include - in words
+vim.opt.path:append("**") -- include subdirs in search
+vim.opt.selection = "inclusive" -- include last char in selection
+vim.opt.mouse = "a" -- enable mouse support
+vim.opt.clipboard:append("unnamedplus") -- use system clipboard
+vim.opt.modifiable = true -- allow buffer modifications
+vim.opt.encoding = "utf-8" -- set encoding
+vim.opt.listchars = { tab = "» ", trail = "·", nbsp = "␣" }
+
+-- vim.opt.guicursor =
+-- "n-v-c:block,i-ci-ve:block,r-cr:hor20,o:hor50,a:blinkwait700-blinkoff400-blinkon250-Cursor/lCursor,sm:block-blinkwait175-blinkoff150-blinkon175" -- cursor blinking and settings
+
+-- Folding: requires treesitter available at runtime; safe fallback if not
+vim.opt.foldmethod = "expr" -- use expression for folding
+vim.opt.foldexpr = "v:lua.vim.treesitter.foldexpr()" -- use treesitter for folding
+vim.opt.foldlevel = 99 -- start with all folds open
+
+vim.opt.splitbelow = true -- horizontal splits go below
+vim.opt.splitright = true -- vertical splits go right
+
+vim.opt.wildmenu = true -- tab completion
+vim.opt.wildmode = "longest:full,full" -- complete longest common match, full completion list, cycle through with Tab
+vim.opt.diffopt:append("linematch:60") -- improve diff display
+vim.opt.redrawtime = 10000 -- increase neovim redraw tolerance
+vim.opt.maxmempattern = 20000 -- increase max memory
+-- ============================================================================
+-- STATUSLINE
+-- ============================================================================
+
+-- Git branch function with caching and Nerd Font icon
+local cached_branch = ""
+local last_check = 0
+local function git_branch()
+ local now = vim.loop.now()
+ if now - last_check > 5000 then -- Check every 5 seconds
+ cached_branch = vim.fn.system("git branch --show-current 2>/dev/null | tr -d '\n'")
+ last_check = now
+ end
+ if cached_branch ~= "" then
+ return "\u{e725} " .. cached_branch .. " " -- nf-dev-git_branch
+ end
+ return ""
+end
+
+-- File type with Nerd Font icon
+local function file_type()
+ local ft = vim.bo.filetype
+ local icons = {
+ lua = "\u{e620} ", -- nf-dev-lua
+ python = "\u{e73c} ", -- nf-dev-python
+ javascript = "\u{e74e} ", -- nf-dev-javascript
+ typescript = "\u{e628} ", -- nf-dev-typescript
+ javascriptreact = "\u{e7ba} ",
+ typescriptreact = "\u{e7ba} ",
+ html = "\u{e736} ", -- nf-dev-html5
+ css = "\u{e749} ", -- nf-dev-css3
+ scss = "\u{e749} ",
+ json = "\u{e60b} ", -- nf-dev-json
+ markdown = "\u{e73e} ", -- nf-dev-markdown
+ vim = "\u{e62b} ", -- nf-dev-vim
+ sh = "\u{f489} ", -- nf-oct-terminal
+ bash = "\u{f489} ",
+ zsh = "\u{f489} ",
+ rust = "\u{e7a8} ", -- nf-dev-rust
+ go = "\u{e724} ", -- nf-dev-go
+ c = "\u{e61e} ", -- nf-dev-c
+ cpp = "\u{e61d} ", -- nf-dev-cplusplus
+ java = "\u{e738} ", -- nf-dev-java
+ php = "\u{e73d} ", -- nf-dev-php
+ ruby = "\u{e739} ", -- nf-dev-ruby
+ swift = "\u{e755} ", -- nf-dev-swift
+ kotlin = "\u{e634} ",
+ dart = "\u{e798} ",
+ elixir = "\u{e62d} ",
+ haskell = "\u{e777} ",
+ sql = "\u{e706} ",
+ yaml = "\u{f481} ",
+ toml = "\u{e615} ",
+ xml = "\u{f05c} ",
+ dockerfile = "\u{f308} ", -- nf-linux-docker
+ gitcommit = "\u{f418} ", -- nf-oct-git_commit
+ gitconfig = "\u{f1d3} ", -- nf-fa-git
+ vue = "\u{fd42} ", -- nf-md-vuejs
+ svelte = "\u{e697} ",
+ astro = "\u{e628} ",
+ }
+
+ if ft == "" then
+ return " \u{f15b} " -- nf-fa-file_o
+ end
+
+ return ((icons[ft] or " \u{f15b} ") .. ft)
+end
+
+-- File size with Nerd Font icon
+local function file_size()
+ local size = vim.fn.getfsize(vim.fn.expand("%"))
+ if size < 0 then
+ return ""
+ end
+ local size_str
+ if size < 1024 then
+ size_str = size .. "B"
+ elseif size < 1024 * 1024 then
+ size_str = string.format("%.1fK", size / 1024)
+ else
+ size_str = string.format("%.1fM", size / 1024 / 1024)
+ end
+ return " \u{f016} " .. size_str .. " " -- nf-fa-file_o
+end
+
+-- Mode indicators with Nerd Font icons
+local function mode_icon()
+ local mode = vim.fn.mode()
+ local modes = {
+ n = " \u{f121} NORMAL",
+ i = " \u{f11c} INSERT",
+ v = " \u{f0168} VISUAL",
+ V = " \u{f0168} V-LINE",
+ ["\22"] = " \u{f0168} V-BLOCK",
+ c = " \u{f120} COMMAND",
+ s = " \u{f0c5} SELECT",
+ S = " \u{f0c5} S-LINE",
+ ["\19"] = " \u{f0c5} S-BLOCK",
+ R = " \u{f044} REPLACE",
+ r = " \u{f044} REPLACE",
+ ["!"] = " \u{f489} SHELL",
+ t = " \u{f120} TERMINAL",
+ }
+ return modes[mode] or (" \u{f059} " .. mode)
+end
+
+_G.mode_icon = mode_icon
+_G.git_branch = git_branch
+_G.file_type = file_type
+_G.file_size = file_size
+
+vim.cmd([[
+ highlight StatusLineBold gui=bold cterm=bold
+]])
+
+-- Function to change statusline based on window focus
+local function setup_dynamic_statusline()
+ vim.api.nvim_create_autocmd({ "WinEnter", "BufEnter" }, {
+ callback = function()
+ vim.opt_local.statusline = table.concat({
+ " ",
+ "%#StatusLineBold#",
+ "%{v:lua.mode_icon()}",
+ "%#StatusLine#",
+ " | %f %h%m%r", -- nf-pl-left_hard_divider
+ " %{v:lua.git_branch()}",
+ " | ", -- nf-pl-left_hard_divider
+ "%{v:lua.file_type()}",
+ " | ", -- nf-pl-left_hard_divider
+ "%{v:lua.file_size()}",
+ "%=", -- Right-align everything after this
+ "%l:%c %P ", -- nf-fa-clock_o for line/col
+ })
+ end,
+ })
+ vim.api.nvim_set_hl(0, "StatusLineBold", { bold = true })
+
+ vim.api.nvim_create_autocmd({ "WinLeave", "BufLeave" }, {
+ callback = function()
+ vim.opt_local.statusline = " %f %h%m%r | %{v:lua.file_type()} %= %l:%c %P "
+ end,
+ })
+end
+
+setup_dynamic_statusline()
+
+-- ============================================================================
+-- KEYMAPS
+-- ============================================================================
+vim.g.mapleader = " " -- space for leader
+vim.g.maplocalleader = " " -- space for localleader
+
+-- better movement in wrapped text
+vim.keymap.set("n", "j", function()
+ return vim.v.count == 0 and "gj" or "j"
+end, { expr = true, silent = true, desc = "Down (wrap-aware)" })
+vim.keymap.set("n", "k", function()
+ return vim.v.count == 0 and "gk" or "k"
+end, { expr = true, silent = true, desc = "Up (wrap-aware)" })
+
+vim.keymap.set("n", "<Esc>", ":nohlsearch<CR>", { desc = "Clear search highlights", silent = true })
+
+vim.keymap.set("n", "n", "nzzzv", { desc = "Next search result (centered)" })
+vim.keymap.set("n", "N", "Nzzzv", { desc = "Previous search result (centered)" })
+vim.keymap.set("n", "<C-d>", "<C-d>zz", { desc = "Half page down (centered)" })
+vim.keymap.set("n", "<C-u>", "<C-u>zz", { desc = "Half page up (centered)" })
+
+vim.keymap.set("n", "<C-h>", "<C-w>h", { desc = "Move to left window" })
+vim.keymap.set("n", "<C-j>", "<C-w>j", { desc = "Move to bottom window" })
+vim.keymap.set("n", "<C-k>", "<C-w>k", { desc = "Move to top window" })
+vim.keymap.set("n", "<C-l>", "<C-w>l", { desc = "Move to right window" })
+
+-- vim.keymap.set("n", "<leader>sv", ":vsplit<CR>", { desc = "Split window vertically" })
+-- vim.keymap.set("n", "<leader>sh", ":split<CR>", { desc = "Split window horizontally" })
+-- vim.keymap.set("n", "<C-Up>", ":resize +2<CR>", { desc = "Increase window height" })
+-- vim.keymap.set("n", "<C-Down>", ":resize -2<CR>", { desc = "Decrease window height" })
+-- vim.keymap.set("n", "<C-Left>", ":vertical resize -2<CR>", { desc = "Decrease window width" })
+-- vim.keymap.set("n", "<C-Right>", ":vertical resize +2<CR>", { desc = "Increase window width" })
+
+vim.keymap.set("n", "<A-j>", ":m .+1<CR>==", { desc = "Move line down" })
+vim.keymap.set("n", "<A-k>", ":m .-2<CR>==", { desc = "Move line up" })
+vim.keymap.set("v", "<A-j>", ":m '>+1<CR>gv=gv", { desc = "Move selection down" })
+vim.keymap.set("v", "<A-k>", ":m '<-2<CR>gv=gv", { desc = "Move selection up" })
+
+vim.keymap.set("v", "<", "<gv", { desc = "Indent left and reselect" })
+vim.keymap.set("v", ">", ">gv", { desc = "Indent right and reselect" })
+
+vim.keymap.set("n", "J", "mzJ`z", { desc = "Join lines and keep cursor position" })
+
+vim.keymap.set("n", "x", '"_x', { noremap = true, silent = true })
+vim.keymap.set("x", "x", '"_x', { noremap = true, silent = true })
+vim.keymap.set("v", "x", '"_x', { noremap = true, silent = true })
+vim.keymap.set("n", "c", '"_c')
+vim.keymap.set("n", "C", '"_C')
+vim.keymap.set("n", "cc", '"_cc')
+vim.keymap.set("x", "c", '"_c')
+
+vim.keymap.set("n", "<leader>pa", function() -- show file path
+ local path = vim.fn.expand("%:p")
+ vim.fn.setreg("+", path)
+ print("file:", path)
+end, { desc = "Copy full file path" })
+
+vim.keymap.set("n", "<leader>td", function()
+ vim.diagnostic.enable(not vim.diagnostic.is_enabled())
+end, { desc = "Toggle diagnostics" })
+vim.keymap.set("n", "<leader>tw", function()
+ vim.diagnostic.enable(not vim.diagnostic.is_enabled())
+ vim.wo.wrap = not vim.wo.wrap
+end, { desc = "Toggle wrap" })
+
+-- ============================================================================
+-- AUTOCMDS
+-- ============================================================================
+
+local augroup = vim.api.nvim_create_augroup("UserConfig", { clear = true })
+
+-- Format on save (ONLY real file buffers, ONLY when efm is attached)
+vim.api.nvim_create_autocmd("BufWritePre", {
+ group = augroup,
+ pattern = {
+ "*.lua",
+ "*.py",
+ "*.go",
+ "*.json",
+ "*.sh",
+ "*.bash",
+ "*.zsh",
+ "*.c",
+ "*.cpp",
+ "*.h",
+ "*.hpp",
+ "*.rs",
+ },
+ callback = function(args)
+ -- avoid formatting non-file buffers (helps prevent weird write prompts)
+ if vim.bo[args.buf].buftype ~= "" then
+ return
+ end
+ if not vim.bo[args.buf].modifiable then
+ return
+ end
+ if vim.api.nvim_buf_get_name(args.buf) == "" then
+ return
+ end
+
+ local has_efm = false
+ for _, c in ipairs(vim.lsp.get_clients({ bufnr = args.buf })) do
+ if c.name == "efm" then
+ has_efm = true
+ break
+ end
+ end
+ if not has_efm then
+ return
+ end
+
+ pcall(vim.lsp.buf.format, {
+ bufnr = args.buf,
+ timeout_ms = 2000,
+ filter = function(c)
+ return c.name == "efm"
+ end,
+ })
+ end,
+})
+
+-- highlight yanked text
+vim.api.nvim_create_autocmd("TextYankPost", {
+ group = augroup,
+ callback = function()
+ vim.hl.on_yank()
+ end,
+})
+
+-- return to last cursor position
+vim.api.nvim_create_autocmd("BufReadPost", {
+ group = augroup,
+ desc = "Restore last cursor position",
+ callback = function()
+ if vim.o.diff then -- except in diff mode
+ return
+ end
+
+ local last_pos = vim.api.nvim_buf_get_mark(0, '"') -- {line, col}
+ local last_line = vim.api.nvim_buf_line_count(0)
+
+ local row = last_pos[1]
+ if row < 1 or row > last_line then
+ return
+ end
+
+ pcall(vim.api.nvim_win_set_cursor, 0, last_pos)
+ end,
+})
+
+-- wrap, linebreak and spellcheck on markdown and text files
+vim.api.nvim_create_autocmd("FileType", {
+ group = augroup,
+ pattern = { "markdown", "text", "gitcommit" },
+ callback = function()
+ vim.opt_local.wrap = true
+ vim.opt_local.linebreak = true
+ vim.opt_local.spell = true
+ end,
+})
+-- ============================================================================
+-- PLUGINS (vim.pack)
+-- ============================================================================
+vim.pack.add({
+ "https://www.github.com/lewis6991/gitsigns.nvim",
+ "https://www.github.com/echasnovski/mini.nvim",
+ "https://www.github.com/ibhagwan/fzf-lua",
+ "https://www.github.com/nvim-tree/nvim-tree.lua",
+ {
+ src = "https://github.com/nvim-treesitter/nvim-treesitter",
+ branch = "main",
+ build = ":TSUpdate",
+ },
+ -- Language Server Protocols
+ "https://www.github.com/neovim/nvim-lspconfig",
+ "https://github.com/mason-org/mason.nvim",
+ "https://github.com/creativenull/efmls-configs-nvim",
+ {
+ src = "https://github.com/saghen/blink.cmp",
+ version = vim.version.range("1.*"),
+ },
+ "https://github.com/L3MON4D3/LuaSnip",
+ "https://github.com/shaunsingh/nord.nvim",
+ "https://github.com/kawre/leetcode.nvim",
+ "https://github.com/nvim-lua/plenary.nvim",
+ "https://github.com/MunifTanjim/nui.nvim",
+ "https://github.com/mrcjkb/rustaceanvim",
+ "https://github.com/folke/which-key.nvim",
+ "https://github.com/hedyhli/outline.nvim",
+ "https://github.com/stevearc/oil.nvim",
+ "https://github.com/folke/flash.nvim",
+ "https://github.com/goolord/alpha-nvim",
+})
+
+local function packadd(name)
+ vim.cmd("packadd " .. name)
+end
+packadd("nvim-treesitter")
+packadd("gitsigns.nvim")
+packadd("mini.nvim")
+packadd("fzf-lua")
+packadd("nvim-tree.lua")
+-- LSP
+packadd("nvim-lspconfig")
+packadd("mason.nvim")
+packadd("efmls-configs-nvim")
+packadd("blink.cmp")
+packadd("LuaSnip")
+packadd("plenary.nvim")
+packadd("nui.nvim")
+packadd("rustaceanvim")
+
+-- ============================================================================
+-- TRANSPARENCY
+-- ============================================================================
+
+local function set_transparent() -- set UI component to transparent
+ local groups = {
+ "Normal",
+ "NormalNC",
+ "EndOfBuffer",
+ "NormalFloat",
+ "FloatBorder",
+ "SignColumn",
+ "StatusLine",
+ "StatusLineNC",
+ "TabLine",
+ "TabLineFill",
+ "TabLineSel",
+ "ColorColumn",
+ }
+ for _, g in ipairs(groups) do
+ vim.api.nvim_set_hl(0, g, { bg = "none" })
+ end
+ vim.api.nvim_set_hl(0, "TabLineFill", { bg = "none", fg = "#767676" })
+end
+
+set_transparent()
+vim.cmd.colorscheme("nord")
+vim.cmd.hi("Comment gui=none")
+-- Set transparency
+vim.cmd("hi Normal guibg=NONE ctermbg=NONE")
+vim.cmd("hi NormalFloat guibg=NONE ctermbg=NONE")
+vim.cmd("hi SignColumn guibg=NONE")
+vim.cmd("hi FloatBorder guibg=NONE")
+vim.cmd("hi CursorLine guibg=NONE")
+
+-- ============================================================================
+-- PLUGIN CONFIGS
+-- ============================================================================
+
+-- ALPHA
+local setup_alpha = function()
+ local alpha = require("alpha")
+ local dashboard = require("alpha.themes.dashboard")
+ dashboard.section.header.val = {
+ [[ ]],
+ [[ ]],
+ [[ ]],
+ [[ ]],
+ [[ ]],
+ [[ ]],
+ [[ __ ]],
+ [[ ___ ___ ___ __ __ /\_\ ___ ___ ]],
+ [[ / _ `\ / __`\ / __`\/\ \/\ \\/\ \ / __` __`\ ]],
+ [[/\ \/\ \/\ __//\ \_\ \ \ \_/ |\ \ \/\ \/\ \/\ \ ]],
+ [[\ \_\ \_\ \____\ \____/\ \___/ \ \_\ \_\ \_\ \_\]],
+ [[ \/_/\/_/\/____/\/___/ \/__/ \/_/\/_/\/_/\/_/]],
+ }
+
+ dashboard.section.buttons.val = {
+ dashboard.button("e", " New file", ":ene <BAR> startinsert <CR>"),
+ dashboard.button("s", " Find file ", ":FzfLua files<CR>"),
+ dashboard.button("g", " Grep ", ":FzfLua live_grep<CR>"),
+ dashboard.button("q", " Quit", ":qa<CR>"),
+ }
+ local elapsed_ms = (vim.loop.hrtime() - _G._startup_time) / 1e6
+
+ dashboard.section.footer.val = {
+ ("Startup: %.2f ms"):format(elapsed_ms),
+ }
+
+ dashboard.config.opts.noautocmd = true
+
+ alpha.setup(dashboard.config)
+end
+
+setup_alpha()
+
+-- FLASH
+require("flash").setup({
+ modes = {
+ search = { enabled = false },
+ char = { enabled = false },
+ treesitter = { enabled = false },
+ remote = { enabled = false },
+ },
+})
+vim.keymap.set({ "n", "x", "o" }, "s", function()
+ require("flash").jump()
+end, { desc = "Flash" })
+
+vim.keymap.set({ "n", "x", "o" }, "R", function()
+ require("flash").treesitter()
+end, { desc = "Flash Treesitter" })
+
+vim.keymap.set("o", "r", function()
+ require("flash").remote()
+end, { desc = "Remote Flash" })
+
+-- OIL
+require("oil").setup({
+ default_file_explorer = true,
+ keymaps = {
+ ["l"] = "actions.select",
+ ["h"] = "actions.parent",
+ ["<CR>"] = "actions.select",
+ ["<C-s>"] = nil,
+ ["<C-h>"] = nil,
+ ["<C-l>"] = nil,
+ },
+ delete_to_trash = true,
+ view_options = {
+ show_hidden = true,
+ },
+ skip_confirm_for_simple_edits = true,
+ float = {
+ max_width = 80,
+ max_height = 30,
+ override = function(conf)
+ return conf
+ end,
+ },
+})
+vim.keymap.set("n", "-", "<CMD>Oil<CR>", { desc = "Open parent directory" })
+
+vim.api.nvim_create_autocmd("FileType", {
+ pattern = "oil",
+ callback = function()
+ vim.opt_local.cursorline = true
+ end,
+})
+
+-- OUTLINE
+require("outline").setup({})
+
+-- TREESITTER
+local setup_treesitter = function()
+ local treesitter = require("nvim-treesitter")
+ treesitter.setup({})
+ local ensure_installed = {
+ "vim",
+ "vimdoc",
+ "rust",
+ "c",
+ "cpp",
+ "go",
+ "json",
+ "lua",
+ "markdown",
+ "python",
+ "bash",
+ "lua",
+ "python",
+ }
+
+ local config = require("nvim-treesitter.config")
+
+ local already_installed = config.get_installed()
+ local parsers_to_install = {}
+
+ for _, parser in ipairs(ensure_installed) do
+ if not vim.tbl_contains(already_installed, parser) then
+ table.insert(parsers_to_install, parser)
+ end
+ end
+
+ if #parsers_to_install > 0 then
+ treesitter.install(parsers_to_install)
+ end
+
+ local group = vim.api.nvim_create_augroup("TreeSitterConfig", { clear = true })
+ vim.api.nvim_create_autocmd("FileType", {
+ group = group,
+ callback = function(args)
+ if vim.list_contains(treesitter.get_installed(), vim.treesitter.language.get_lang(args.match)) then
+ vim.treesitter.start(args.buf)
+ end
+ end,
+ })
+end
+
+setup_treesitter()
+
+-- NVIM-TREE
+
+require("nvim-tree").setup({
+ view = {
+ side = "right",
+ width = 35,
+ },
+ filters = {
+ dotfiles = false,
+ },
+ renderer = {
+ group_empty = true,
+ },
+})
+vim.keymap.set("n", "<leader>e", function()
+ require("nvim-tree.api").tree.toggle()
+end, { desc = "Toggle NvimTree" })
+
+vim.api.nvim_set_hl(0, "NvimTreeNormalNC", { bg = "none" })
+vim.api.nvim_set_hl(0, "SignColumn", { bg = "none" })
+vim.api.nvim_set_hl(0, "NvimTreeSignColumn", { bg = "none" })
+vim.api.nvim_set_hl(0, "NvimTreeNormal", { bg = "none" })
+vim.api.nvim_set_hl(0, "NvimTreeWinSeparator", { fg = "#2a2a2a", bg = "none" })
+vim.api.nvim_set_hl(0, "NvimTreeEndOfBuffer", { bg = "none" })
+
+-- WHICH-KEY
+require("which-key").setup({
+ win = {
+ wo = {
+ winblend = 0,
+ },
+ },
+ preset = "helix",
+ icons = {
+ rules = false,
+ },
+ delay = 500,
+ -- spec = {
+ -- { "<leader>c", group = "Code", mode = { "n", "x" } },
+ -- { "<leader>d", group = "Document" },
+ -- { "<leader>g", group = "Git" },
+ -- { "<leader>m", group = "Marks" },
+ -- { "<leader>r", group = "Rename" },
+ -- { "<leader>s", group = "Search" },
+ -- { "<leader>t", group = "Toggle" },
+ -- { "<leader>w", group = "Workspace" },
+ -- { "<leader>l", group = "LSP" },
+ -- },
+})
+
+-- NOTIFICATION HISTORY
+vim.keymap.set("n", "<leader>n", function()
+ local notify = require("mini.notify")
+
+ local history = notify.get_all and notify.get_all() or {}
+
+ local lines = {}
+
+ for _, item in ipairs(history) do
+ local time = item.time and os.date("%H:%M:%S", item.time) or ""
+ table.insert(lines, time .. " | " .. (item.msg or ""))
+ end
+
+ local buf = vim.api.nvim_create_buf(false, true)
+ vim.api.nvim_buf_set_lines(buf, 0, -1, false, lines)
+
+ local width = math.floor(vim.o.columns * 0.7)
+ local height = math.floor(vim.o.lines * 0.7)
+
+ local win = vim.api.nvim_open_win(buf, true, {
+ relative = "editor",
+ width = width,
+ height = height,
+ row = math.floor((vim.o.lines - height) / 2),
+ col = math.floor((vim.o.columns - width) / 2),
+ style = "minimal",
+ border = "rounded",
+ })
+
+ vim.bo[buf].buftype = "nofile"
+ vim.bo[buf].swapfile = false
+
+ vim.keymap.set("n", "q", function()
+ if vim.api.nvim_win_is_valid(win) then
+ vim.api.nvim_win_close(win, true)
+ end
+ if vim.api.nvim_buf_is_valid(buf) then
+ vim.api.nvim_buf_delete(buf, { force = true })
+ end
+ end, { buffer = buf, silent = true })
+end, { desc = "Show notification history" })
+
+-- FZF-LUA
+
+require("fzf-lua").setup({
+ keymap = {
+ builtin = {
+ ["<S-j>"] = "preview-page-down",
+ ["<S-k>"] = "preview-page-up",
+ },
+ },
+ winopts = {
+ row = 1,
+ col = 0,
+ width = 1,
+ height = 0.4,
+ title_pos = "left",
+ preview = {
+ layout = "horizontal",
+ title_pos = "right",
+ },
+ },
+})
+
+vim.keymap.set("n", "<leader>s", function()
+ require("fzf-lua").files()
+end, { desc = "FZF Files" })
+vim.keymap.set("n", "<leader>/", function()
+ require("fzf-lua").live_grep()
+end, { desc = "FZF Live Grep" })
+vim.keymap.set("n", "<leader><leader>", function()
+ require("fzf-lua").buffers()
+end, { desc = "FZF Buffers" })
+vim.keymap.set("n", "<leader>fh", function()
+ require("fzf-lua").help_tags()
+end, { desc = "FZF Help Tags" })
+vim.keymap.set("n", "<leader>fx", function()
+ require("fzf-lua").diagnostics_document()
+end, { desc = "FZF Diagnostics Document" })
+vim.keymap.set("n", "<leader>fX", function()
+ require("fzf-lua").diagnostics_workspace()
+end, { desc = "FZF Diagnostics Workspace" })
+
+-- MINI
+require("mini.surround").setup({})
+require("mini.pairs").setup({})
+require("mini.ai").setup({})
+require("mini.comment").setup({})
+local MiniNotify = require("mini.notify")
+
+MiniNotify.setup({
+ window = {
+ winblend = 0,
+ },
+})
+
+vim.notify = MiniNotify.make_notify({
+ ERROR = { duration = 4000 },
+ WARN = { duration = 3000 },
+ INFO = { duration = 2000 },
+ DEBUG = { duration = 0 },
+ TRACE = { duration = 0 },
+})
+require("mini.icons").setup({})
+
+require("gitsigns").setup({
+ signs = {
+ add = { text = "\u{2590}" }, -- ▏
+ change = { text = "\u{2590}" }, -- ▐
+ delete = { text = "\u{2590}" }, -- ◦
+ topdelete = { text = "\u{25e6}" }, -- ◦
+ changedelete = { text = "\u{25cf}" }, -- ●
+ untracked = { text = "\u{25cb}" }, -- ○
+ },
+ signcolumn = true,
+ current_line_blame = false,
+})
+
+-- MASON
+require("mason").setup({})
+
+-- GIT
+vim.keymap.set("n", "]h", function()
+ require("gitsigns").next_hunk()
+end, { desc = "Next git hunk" })
+vim.keymap.set("n", "[h", function()
+ require("gitsigns").prev_hunk()
+end, { desc = "Previous git hunk" })
+vim.keymap.set("n", "<leader>hs", function()
+ require("gitsigns").stage_hunk()
+end, { desc = "Stage hunk" })
+vim.keymap.set("n", "<leader>hr", function()
+ require("gitsigns").reset_hunk()
+end, { desc = "Reset hunk" })
+vim.keymap.set("n", "<leader>hp", function()
+ require("gitsigns").preview_hunk()
+end, { desc = "Preview hunk" })
+vim.keymap.set("n", "<leader>hb", function()
+ require("gitsigns").blame_line({ full = true })
+end, { desc = "Blame line" })
+vim.keymap.set("n", "<leader>hB", function()
+ require("gitsigns").toggle_current_line_blame()
+end, { desc = "Toggle inline blame" })
+vim.keymap.set("n", "<leader>hd", function()
+ require("gitsigns").diffthis()
+end, { desc = "Diff this" })
+
+-- LEET CODE
+require("leetcode").setup({
+ lang = "rust",
+ storage = {
+ home = vim.fn.expand("~/leetcode"),
+ cache = vim.fn.stdpath("cache") .. "/leetcode",
+ },
+ image_support = false,
+})
+
+-- ============================================================================
+-- LSP, Linting, Formatting & Completion
+-- ============================================================================
+local diagnostic_signs = {
+ Error = " ",
+ Warn = " ",
+ Hint = "",
+ Info = "",
+}
+
+vim.diagnostic.config({
+ virtual_text = { prefix = "●", spacing = 4 },
+ signs = {
+ text = {
+ [vim.diagnostic.severity.ERROR] = diagnostic_signs.Error,
+ [vim.diagnostic.severity.WARN] = diagnostic_signs.Warn,
+ [vim.diagnostic.severity.INFO] = diagnostic_signs.Info,
+ [vim.diagnostic.severity.HINT] = diagnostic_signs.Hint,
+ },
+ },
+ underline = true,
+ update_in_insert = false,
+ severity_sort = true,
+ float = {
+ border = "rounded",
+ source = "always",
+ header = "",
+ prefix = "",
+ focusable = false,
+ style = "minimal",
+ },
+})
+
+do
+ local orig = vim.lsp.util.open_floating_preview
+ function vim.lsp.util.open_floating_preview(contents, syntax, opts, ...)
+ opts = opts or {}
+ opts.border = opts.border or "rounded"
+ return orig(contents, syntax, opts, ...)
+ end
+end
+
+local function lsp_on_attach(ev)
+ local client = vim.lsp.get_client_by_id(ev.data.client_id)
+ if not client then
+ return
+ end
+
+ local bufnr = ev.buf
+ local opts = { noremap = true, silent = true, buffer = bufnr }
+
+ vim.keymap.set("n", "<leader>gd", function()
+ require("fzf-lua").lsp_definitions({ jump_to_single_result = true })
+ end, opts)
+
+ vim.keymap.set("n", "<leader>gD", vim.lsp.buf.definition, opts)
+
+ vim.keymap.set("n", "<leader>gS", function()
+ vim.cmd("vsplit")
+ vim.lsp.buf.definition()
+ end, opts)
+
+ vim.keymap.set("n", "<leader>ca", vim.lsp.buf.code_action, opts)
+ vim.keymap.set("n", "<leader>rn", vim.lsp.buf.rename, opts)
+
+ vim.keymap.set("n", "<leader>D", function()
+ vim.diagnostic.open_float({ scope = "line" })
+ end, opts)
+ vim.keymap.set("n", "<leader>d", function()
+ vim.diagnostic.open_float({ scope = "cursor" })
+ end, opts)
+ vim.keymap.set("n", "<leader>nd", function()
+ vim.diagnostic.jump({ count = 1 })
+ end, opts)
+
+ vim.keymap.set("n", "<leader>pd", function()
+ vim.diagnostic.jump({ count = -1 })
+ end, opts)
+
+ vim.keymap.set("n", "K", vim.lsp.buf.hover, opts)
+
+ vim.keymap.set("n", "<leader>fd", function()
+ require("fzf-lua").lsp_definitions({ jump_to_single_result = true })
+ end, opts)
+ vim.keymap.set("n", "<leader>fr", function()
+ require("fzf-lua").lsp_references()
+ end, opts)
+ vim.keymap.set("n", "<leader>ft", function()
+ require("fzf-lua").lsp_typedefs()
+ end, opts)
+ vim.keymap.set("n", "<leader>fs", function()
+ require("fzf-lua").lsp_document_symbols()
+ end, opts)
+ vim.keymap.set("n", "<leader>fw", function()
+ require("fzf-lua").lsp_workspace_symbols()
+ end, opts)
+ vim.keymap.set("n", "<leader>fi", function()
+ require("fzf-lua").lsp_implementations()
+ end, opts)
+
+ if client:supports_method("textDocument/codeAction", bufnr) then
+ vim.keymap.set("n", "<leader>oi", function()
+ vim.lsp.buf.code_action({
+ context = { only = { "source.organizeImports" }, diagnostics = {} },
+ apply = true,
+ bufnr = bufnr,
+ })
+ vim.defer_fn(function()
+ vim.lsp.buf.format({ bufnr = bufnr })
+ end, 50)
+ end, opts)
+ end
+end
+
+vim.api.nvim_create_autocmd("LspAttach", { group = augroup, callback = lsp_on_attach })
+
+vim.keymap.set("n", "<leader>q", function()
+ vim.diagnostic.setloclist({ open = true })
+end, { desc = "Open diagnostic list" })
+vim.keymap.set("n", "<leader>dl", vim.diagnostic.open_float, { desc = "Show line diagnostics" })
+
+-- AUTOCOMPLETE
+require("blink.cmp").setup({
+ keymap = {
+ preset = "default",
+ },
+ appearance = { nerd_font_variant = "mono" },
+ completion = { menu = { auto_show = true } },
+ sources = { default = { "lsp", "path", "buffer", "snippets" } },
+ snippets = {
+ expand = function(snippet)
+ require("luasnip").lsp_expand(snippet)
+ end,
+ },
+
+ fuzzy = {
+ implementation = "prefer_rust",
+ prebuilt_binaries = { download = true },
+ },
+})
+
+vim.lsp.config["*"] = {
+ capabilities = require("blink.cmp").get_lsp_capabilities(),
+}
+
+vim.lsp.config("lua_ls", {
+ settings = {
+ Lua = {
+ diagnostics = { globals = { "vim" } },
+ telemetry = { enable = false },
+ },
+ },
+})
+vim.lsp.config("pyright", {
+ settings = {
+ python = {
+ pythonPath = vim.fn.getcwd() .. "/.venv/bin/python",
+
+ analysis = {
+ autoSearchPaths = true,
+ useLibraryCodeForTypes = true,
+ diagnosticMode = "workspace",
+ },
+ },
+ },
+})
+vim.lsp.config("bashls", {})
+vim.lsp.config("ts_ls", {})
+vim.lsp.config("gopls", {})
+vim.lsp.config("clangd", {})
+
+local capabilities = vim.lsp.protocol.make_client_capabilities()
+
+local ok, blink = pcall(require, "blink.cmp")
+if ok then
+ capabilities = blink.get_lsp_capabilities(capabilities)
+end
+
+vim.g.rustaceanvim = {
+ tools = {
+ enable_clippy = false,
+ },
+
+ server = {
+ capabilities = capabilities,
+
+ standalone = true,
+
+ status_notify_level = false,
+
+ load_vscode_settings = false,
+
+ default_settings = {
+ ["rust-analyzer"] = {
+ checkOnSave = false,
+ },
+ },
+ },
+}
+
+do
+ local luacheck = require("efmls-configs.linters.luacheck")
+ local stylua = require("efmls-configs.formatters.stylua")
+
+ local flake8_base = require("efmls-configs.linters.flake8")
+
+ local function resolve_flake8()
+ local cwd = vim.fn.getcwd()
+ local venv_flake8 = cwd .. "/.venv/bin/flake8"
+
+ if vim.fn.executable(venv_flake8) == 1 then
+ vim.notify("efm: using project flake8 → " .. venv_flake8, vim.log.levels.INFO)
+ return venv_flake8
+ end
+
+ if vim.fn.executable("flake8") == 1 then
+ return "flake8"
+ end
+
+ return nil
+ end
+
+ local flake8_cmd = resolve_flake8()
+
+ local flake8 = nil
+ if flake8_cmd then
+ flake8 = vim.tbl_extend("force", flake8_base, {
+ lintCommand = flake8_cmd .. " --max-line-length=999 --stdin-display-name ${INPUT} -",
+ })
+ end
+ local black = require("efmls-configs.formatters.black")
+
+ local prettier_d = require("efmls-configs.formatters.prettier_d")
+ local eslint_d = require("efmls-configs.linters.eslint_d")
+
+ local fixjson = require("efmls-configs.formatters.fixjson")
+
+ local shellcheck = require("efmls-configs.linters.shellcheck")
+ local shfmt = require("efmls-configs.formatters.shfmt")
+
+ local cpplint = require("efmls-configs.linters.cpplint")
+ local clangfmt = require("efmls-configs.formatters.clang_format")
+
+ local go_revive = require("efmls-configs.linters.go_revive")
+ local gofumpt = require("efmls-configs.formatters.gofumpt")
+
+ local rustfmt = require("efmls-configs.formatters.rustfmt")
+
+ vim.lsp.config("efm", {
+ filetypes = {
+ "c",
+ "cpp",
+ "css",
+ "go",
+ "html",
+ "javascript",
+ "javascriptreact",
+ "json",
+ "jsonc",
+ "lua",
+ "markdown",
+ "python",
+ "sh",
+ "typescript",
+ "typescriptreact",
+ "vue",
+ "svelte",
+ },
+ init_options = { documentFormatting = true },
+ settings = {
+ languages = {
+ c = { clangfmt, cpplint },
+ go = { gofumpt, go_revive },
+ cpp = { clangfmt, cpplint },
+ css = { prettier_d },
+ html = { prettier_d },
+ javascript = { eslint_d, prettier_d },
+ javascriptreact = { eslint_d, prettier_d },
+ json = { eslint_d, fixjson },
+ jsonc = { eslint_d, fixjson },
+ lua = { luacheck, stylua },
+ markdown = { prettier_d },
+ python = { flake8, black },
+ sh = { shellcheck, shfmt },
+ typescript = { eslint_d, prettier_d },
+ typescriptreact = { eslint_d, prettier_d },
+ vue = { eslint_d, prettier_d },
+ svelte = { eslint_d, prettier_d },
+ rust = { rustfmt },
+ },
+ },
+ })
+end
+
+vim.lsp.enable({
+ "lua_ls",
+ "pyright",
+ "bashls",
+ "ts_ls",
+ "gopls",
+ "clangd",
+ "efm",
+})
diff --git a/.config/nvim/lazy-lock.json b/.config/nvim/lazy-lock.json
deleted file mode 100644
index 2130986..0000000
--- a/.config/nvim/lazy-lock.json
+++ /dev/null
@@ -1,46 +0,0 @@
-{
- "LuaSnip": { "branch": "master", "commit": "5a1e39223db9a0498024a77b8441169d260c8c25" },
- "blink-emoji.nvim": { "branch": "master", "commit": "066013e4c98a9318408ee3f1ca2dbcb6fa3e4c06" },
- "blink.cmp": { "branch": "main", "commit": "4b18c32adef2898f95cdef6192cbd5796c1a332d" },
- "blink.compat": { "branch": "main", "commit": "2ed6d9a28b07fa6f3bface818470605f8896408c" },
- "bullets.vim": { "branch": "master", "commit": "89294b8930e660936374fb763ac48a1ac51dd29c" },
- "cmp-sql": { "branch": "master", "commit": "54193ac99e3855c6ffaa36f83a7c50213df03157" },
- "conform.nvim": { "branch": "master", "commit": "c2526f1cde528a66e086ab1668e996d162c75f4f" },
- "csharp.nvim": { "branch": "main", "commit": "e44e275dabbcfc188ce1a5f504aad778e917c814" },
- "fidget.nvim": { "branch": "main", "commit": "7fa433a83118a70fe24c1ce88d5f0bd3453c0970" },
- "flash.nvim": { "branch": "main", "commit": "fcea7ff883235d9024dc41e638f164a450c14ca2" },
- "friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" },
- "fzf-lua": { "branch": "main", "commit": "9004cbb4c065a32b690e909c49903967b45301eb" },
- "gitsigns.nvim": { "branch": "main", "commit": "9f3c6dd7868bcc116e9c1c1929ce063b978fa519" },
- "lazy.nvim": { "branch": "main", "commit": "306a05526ada86a7b30af95c5cc81ffba93fef97" },
- "leetcode.nvim": { "branch": "master", "commit": "fdd3f91800b3983e27bc9fcfb99cfa7293d7f11a" },
- "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" },
- "markdown-preview.nvim": { "branch": "master", "commit": "a923f5fc5ba36a3b17e289dc35dc17f66d0548ee" },
- "mason-lspconfig.nvim": { "branch": "main", "commit": "21c2a84ce368e99b18f52ab348c4c02c32c02fcf" },
- "mason-tool-installer.nvim": { "branch": "main", "commit": "443f1ef8b5e6bf47045cb2217b6f748a223cf7dc" },
- "mason.nvim": { "branch": "main", "commit": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65" },
- "mini.icons": { "branch": "main", "commit": "68c178e0958d95b3977a771f3445429b1bded985" },
- "mini.nvim": { "branch": "main", "commit": "dbb073bd2ed4a7bb35daafc7989567f0ff1426ee" },
- "neo-tree.nvim": { "branch": "v3.x", "commit": "f3df514fff2bdd4318127c40470984137f87b62e" },
- "nord.nvim": { "branch": "master", "commit": "80c1e5321505aeb22b7a9f23eb82f1e193c12470" },
- "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" },
- "nvim-colorizer.lua": { "branch": "master", "commit": "338409dd8a6ed74767bad3eb5269f1b903ffb3cf" },
- "nvim-dap": { "branch": "master", "commit": "b516f20b487b0ac6a281e376dfac1d16b5040041" },
- "nvim-lspconfig": { "branch": "master", "commit": "44acfe887d4056f704ccc4f17513ed41c9e2b2e6" },
- "nvim-osc52": { "branch": "main", "commit": "04cfaba1865ae5c53b6f887c3ca7304973824fb2" },
- "nvim-treesitter": { "branch": "main", "commit": "dc42c209f3820bdfaae0956f15de29689aa6b451" },
- "nvim-web-devicons": { "branch": "master", "commit": "746ffbb17975ebd6c40142362eee1b0249969c5c" },
- "oil.nvim": { "branch": "master", "commit": "f55b25e493a7df76371cfadd0ded5004cb9cd48a" },
- "outline.nvim": { "branch": "main", "commit": "ead1820d49c8e79ce89cab1c2c318981b695c9d2" },
- "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" },
- "rainbow-delimiters.nvim": { "branch": "master", "commit": "e2858c43caafec291f915ef25fbed27bbe78abbd" },
- "render-markdown.nvim": { "branch": "main", "commit": "48b4175dbca8439d30c1f52231cbe5a712c8f9d9" },
- "rustaceanvim": { "branch": "master", "commit": "88575b98bb9937fb9983ddec5e532b67e75ce677" },
- "snacks.nvim": { "branch": "main", "commit": "fe7cfe9800a182274d0f868a74b7263b8c0c020b" },
- "structlog.nvim": { "branch": "main", "commit": "45b26a2b1036bb93c0e83f4225e85ab3cee8f476" },
- "typst-preview.nvim": { "branch": "master", "commit": "e123a7ab64e52d836e00dea9251e85b201f38966" },
- "undotree": { "branch": "master", "commit": "d8f99084d98c32f651860eb0baaf89759f91debc" },
- "uv.nvim": { "branch": "main", "commit": "b0bce1b61584fde99c316aa0587a4996c52df206" },
- "vim-tmux-navigator": { "branch": "master", "commit": "e41c431a0c7b7388ae7ba341f01a0d217eb3a432" },
- "which-key.nvim": { "branch": "main", "commit": "3aab2147e74890957785941f0c1ad87d0a44c15a" }
-}
diff --git a/.config/nvim/lua/autocmds.lua b/.config/nvim/lua/autocmds.lua
deleted file mode 100644
index 13f235c..0000000
--- a/.config/nvim/lua/autocmds.lua
+++ /dev/null
@@ -1,28 +0,0 @@
-vim.api.nvim_create_autocmd("TextYankPost", {
- desc = "Highlight when yanking (copying) text",
- group = vim.api.nvim_create_augroup("kickstart-highlight-yank", { clear = true }),
- callback = function()
- vim.highlight.on_yank()
- end,
-})
-
-vim.api.nvim_create_autocmd("FileType", {
- pattern = { "gitcommit", "markdown" },
- callback = function(event)
- vim.keymap.set("i", "`", "`", { buffer = event.buf })
- end,
-})
-
-vim.api.nvim_create_autocmd("InsertEnter", {
- pattern = "*.md",
- callback = function()
- vim.opt.conceallevel = 0
- end,
-})
-
-vim.api.nvim_create_autocmd("InsertLeave", {
- pattern = "*.md",
- callback = function()
- vim.opt.conceallevel = 3
- end,
-})
diff --git a/.config/nvim/lua/config/lazy.lua b/.config/nvim/lua/config/lazy.lua
deleted file mode 100644
index ba9b8f3..0000000
--- a/.config/nvim/lua/config/lazy.lua
+++ /dev/null
@@ -1,36 +0,0 @@
--- Bootstrap lazy.nvim
-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
-
--- Hey! Put lazy into the runtimepath for neovim!
-vim.opt.runtimepath:prepend(lazypath)
-
--- Make sure to setup `mapleader` and `maplocalleader` before
--- loading lazy.nvim so that mappings are correct.
--- This is also a good place to setup other settings (vim.opt)
--- Setup lazy.nvim
-require("lazy").setup({
- spec = {
- { import = "config.plugins" },
- },
- ui = {
- backdrop = 100,
- },
- change_detection = {
- -- automatically check for config file changes and reload the ui
- enabled = false,
- notify = false, -- get a notification when changes are found
- },
-})
diff --git a/.config/nvim/lua/config/plugins/blink-cmp.lua b/.config/nvim/lua/config/plugins/blink-cmp.lua
deleted file mode 100644
index 9f622c7..0000000
--- a/.config/nvim/lua/config/plugins/blink-cmp.lua
+++ /dev/null
@@ -1,125 +0,0 @@
-return {
- {
- "saghen/blink.compat",
- version = "*",
- lazy = true,
- opts = {},
- },
- {
- "saghen/blink.cmp",
- event = "VeryLazy",
- -- optional: provides snippets for the snippet source
- dependencies = {
- "rafamadriz/friendly-snippets",
- "moyiz/blink-emoji.nvim",
- "ray-x/cmp-sql",
- },
-
- -- use a release tag to download pre-built binaries
- version = "1.*",
- -- AND/OR build from source, requires nightly: https://rust-lang.github.io/rustup/concepts/channels.html#working-with-nightly-rust
- -- build = 'cargo build --release',
- -- If you use nix, you can build from source using latest nightly rust with:
- -- build = 'nix run .#build-plugin',
- opts = {
- snippets = {
- preset = "luasnip", -- Choose LuaSnip as the snippet engine
- },
- -- 'default' (recommended) for mappings similar to built-in completions (C-y to accept)
- -- 'super-tab' for mappings similar to vscode (tab to accept)
- -- 'enter' for enter to accept
- -- 'none' for no mappings
- --
- -- All presets have the following mappings:
- -- C-space: Open menu or open docs if already open
- -- C-n/C-p or Up/Down: Select next/previous item
- -- C-e: Hide menu
- -- C-k: Toggle signature help (if signature.enabled = true)
- --
- -- See :h blink-cmp-config-keymap for defining your own keymap
- keymap = {
- preset = "default",
- },
-
- appearance = {
- -- 'mono' (default) for 'Nerd Font Mono' or 'normal' for 'Nerd Font'
- -- Adjusts spacing to ensure icons are aligned
- nerd_font_variant = "mono",
- },
-
- -- (Default) Only show the documentation popup when manually triggered
- completion = {
- menu = { auto_show = true },
- trigger = {
- show_on_keyword = true,
- show_on_trigger_character = true,
- show_on_insert_on_trigger_character = true,
- },
- documentation = { auto_show = true, window = { border = "single" } },
- },
- signature = { enabled = true },
-
- sources = {
- default = { "lsp", "path", "snippets", "buffer", "emoji", "sql" },
- providers = {
- lsp = {
- name = "LSP",
- module = "blink.cmp.sources.lsp",
- min_keyword_length = 0,
- },
- snippets = {
- name = "snippets",
- module = "blink.cmp.sources.snippets",
- enabled = true,
- min_keyword_length = 2,
- score_offset = 80,
- },
- emoji = {
- module = "blink-emoji",
- name = "Emoji",
- score_offset = 15, -- Tune by preference
- opts = { insert = true }, -- Insert emoji (default) or complete its name
- -- should_show_items = function()
- -- return vim.tbl_contains(
- -- -- Enable emoji completion only for git commits and markdown.
- -- -- By default, enabled for all file-types.
- -- { "gitcommit", "markdown" },
- -- vim.o.filetype
- -- )
- -- end,
- },
- sql = {
- -- IMPORTANT: use the same name as you would for nvim-cmp
- name = "sql",
- module = "blink.compat.source",
-
- -- all blink.cmp source config options work as normal:
- score_offset = -3,
-
- -- this table is passed directly to the proxied completion source
- -- as the `option` field in nvim-cmp's source config
- --
- -- this is NOT the same as the opts in a plugin's lazy.nvim spec
- opts = {},
- should_show_items = function()
- return vim.tbl_contains(
- -- Enable emoji completion only for git commits and markdown.
- -- By default, enabled for all file-types.
- { "sql" },
- vim.o.filetype
- )
- end,
- },
- },
- },
-
- -- (Default) Rust fuzzy matcher for typo resistance and significantly better performance
- -- You may use a lua implementation instead by using `implementation = "lua"` or fallback to the lua implementation,
- -- when the Rust fuzzy matcher is not available, by using `implementation = "prefer_rust"`
- --
- -- See the fuzzy documentation for more information
- fuzzy = { implementation = "prefer_rust_with_warning" },
- },
- opts_extend = { "sources.default" },
- },
-}
diff --git a/.config/nvim/lua/config/plugins/colorscheme.lua b/.config/nvim/lua/config/plugins/colorscheme.lua
deleted file mode 100644
index ea130c7..0000000
--- a/.config/nvim/lua/config/plugins/colorscheme.lua
+++ /dev/null
@@ -1,14 +0,0 @@
-return {
- "shaunsingh/nord.nvim",
- priority = 1000,
- init = function()
- vim.cmd.colorscheme("nord")
- vim.cmd.hi("Comment gui=none")
- -- Set transparency
- vim.cmd("hi Normal guibg=NONE ctermbg=NONE")
- vim.cmd("hi NormalFloat guibg=NONE ctermbg=NONE")
- vim.cmd("hi SignColumn guibg=NONE")
- vim.cmd("hi FloatBorder guibg=NONE")
- vim.cmd("hi CursorLine guibg=NONE")
- end,
-}
diff --git a/.config/nvim/lua/config/plugins/conform.lua b/.config/nvim/lua/config/plugins/conform.lua
deleted file mode 100644
index 5747200..0000000
--- a/.config/nvim/lua/config/plugins/conform.lua
+++ /dev/null
@@ -1,40 +0,0 @@
-return {
- "stevearc/conform.nvim",
- event = "VeryLazy",
- keys = {
- {
- "<leader>f",
- function()
- require("conform").format({ async = true, lsp_format = "fallback" })
- end,
- mode = "",
- desc = "Format buffer",
- },
- },
-
- opts = {
- formatters_by_ft = {
- lua = { "stylua" },
- python = { "isort", "black" },
- rust = { "rustfmt" },
- javascript = { "prettierd", "prettier", stop_after_first = true },
- typescript = { "prettierd", "prettier", stop_after_first = true },
- typescriptreact = { "prettierd", "prettier", stop_after_first = true },
- css = { "prettierd", "prettier", stop_after_first = true },
- html = { "prettierd", "prettier", stop_after_first = true },
- typst = { "prettypst" },
- xml = { "xmlformatter" },
- },
- format_on_save = {
- timeout_ms = 500,
- lsp_format = "fallback",
- },
- formatters = {
- xmlformat = {
- command = "xmlformat",
- args = { "--selfclose", "-" },
- stdin = true,
- },
- },
- },
-}
diff --git a/.config/nvim/lua/config/plugins/flash.lua b/.config/nvim/lua/config/plugins/flash.lua
deleted file mode 100644
index feec135..0000000
--- a/.config/nvim/lua/config/plugins/flash.lua
+++ /dev/null
@@ -1,18 +0,0 @@
-return {
- "folke/flash.nvim",
- event = "VeryLazy",
- opts = {
- modes = {
- search = { enabled = false },
- char = { enabled = false },
- treesitter = { enabled = false },
- remote = { enabled = false },
- },
- },
- -- stylua: ignore
- keys = {
- { "s", mode = { "n", "x", "o" }, function() require("flash").jump() end, desc = "Flash" },
- { "R", mode = { "n", "x", "o" }, function() require("flash").treesitter() end, desc = "Flash Treesitter" },
- { "r", mode = "o", function() require("flash").remote() end, desc = "Remote Flash" },
- },
-}
diff --git a/.config/nvim/lua/config/plugins/fzflua.lua b/.config/nvim/lua/config/plugins/fzflua.lua
deleted file mode 100644
index 8dfdeb3..0000000
--- a/.config/nvim/lua/config/plugins/fzflua.lua
+++ /dev/null
@@ -1,29 +0,0 @@
-return {
- "ibhagwan/fzf-lua",
- event = "VeryLazy",
- dependencies = { "echasnovski/mini.icons" },
- opts = {
- keymap = {
- builtin = {
- ["<S-j>"] = "preview-page-down",
- ["<S-k>"] = "preview-page-up",
- },
- },
- winopts = {
- row = 1,
- col = 0,
- width = 1,
- height = 0.4,
- title_pos = "left",
- preview = {
- layout = "horizontal",
- title_pos = "right",
- },
- },
- files = {
- -- Show hidden files but respect .gitignore
- -- rg_opts = [[--color=never --hidden --files -g "!.git" --ignore-file ~/.config/git/ignore]],
- -- fd_opts = [[--color=never --hidden --type f --type l --exclude .git --ignore-file ~/.config/git/ignore]],
- },
- },
-}
diff --git a/.config/nvim/lua/config/plugins/gitsigns.lua b/.config/nvim/lua/config/plugins/gitsigns.lua
deleted file mode 100644
index 13c3b20..0000000
--- a/.config/nvim/lua/config/plugins/gitsigns.lua
+++ /dev/null
@@ -1,36 +0,0 @@
-return {
- {
- "lewis6991/gitsigns.nvim",
- event = "VeryLazy",
- opts = {
- signs = {
- add = { text = "▎" },
- change = { text = "▎" },
- delete = { text = "" },
- topdelete = { text = "" },
- changedelete = { text = "▎" },
- untracked = { text = "▎" },
- },
- on_attach = function(buffer)
- local gs = package.loaded.gitsigns
-
- local function map(mode, l, r, desc)
- vim.keymap.set(mode, l, r, { buffer = buffer, desc = desc })
- end
-
- -- stylua: ignore start
- map("n", "]g", gs.next_hunk, "Next Hunk")
- map("n", "[g", gs.prev_hunk, "Prev Hunk")
- map({ "n", "v" }, "<leader>gs", ":Gitsigns stage_hunk<CR>", "Stage Hunk")
- map({ "n", "v" }, "<leader>gr", ":Gitsigns reset_hunk<CR>", "Reset Hunk")
- map("n", "<leader>gS", gs.stage_buffer, "Stage Buffer")
- map("n", "<leader>gd", gs.diffthis, "Diff this")
- map("n", "<leader>gu", gs.undo_stage_hunk, "Undo Stage Hunk")
- map("n", "<leader>gR", gs.reset_buffer, "Reset Buffer")
- map("n", "<leader>gp", gs.preview_hunk, "Preview Hunk")
- map("n", "<leader>gb", function() gs.blame_line({ full = true }) end, "Blame Line")
- map({ "o", "x" }, "ih", ":<C-U>Gitsigns select_hunk<CR>", "GitSigns Select Hunk")
- end,
- },
- },
-}
diff --git a/.config/nvim/lua/config/plugins/leetcode.lua b/.config/nvim/lua/config/plugins/leetcode.lua
deleted file mode 100644
index 920aba9..0000000
--- a/.config/nvim/lua/config/plugins/leetcode.lua
+++ /dev/null
@@ -1,22 +0,0 @@
-return {
- "kawre/leetcode.nvim",
- build = function()
- if vim.fn.exists(":TSUpdate") == 2 then
- vim.cmd("TSUpdate html")
- end
- end,
- dependencies = {
- -- include a picker of your choice, see picker section for more details
- "nvim-lua/plenary.nvim",
- "MunifTanjim/nui.nvim",
- },
- opts = {
- -- configuration goes here
- lang = "rust",
- storage = {
- home = vim.fn.expand("~/leetcode"),
- cache = vim.fn.stdpath("cache") .. "/leetcode",
- },
- image_support = false,
- },
-}
diff --git a/.config/nvim/lua/config/plugins/lsp.lua b/.config/nvim/lua/config/plugins/lsp.lua
deleted file mode 100644
index eb812d2..0000000
--- a/.config/nvim/lua/config/plugins/lsp.lua
+++ /dev/null
@@ -1,240 +0,0 @@
-return {
- "neovim/nvim-lspconfig",
- event = "VeryLazy",
- dependencies = {
- { "williamboman/mason.nvim", opts = {} },
- "williamboman/mason-lspconfig.nvim",
- "WhoIsSethDaniel/mason-tool-installer.nvim",
- {
- "j-hui/fidget.nvim",
- opts = {
- notification = {
- window = {
- winblend = 0,
- },
- },
- },
- },
- },
- config = function()
- vim.api.nvim_create_autocmd("LspAttach", {
- group = vim.api.nvim_create_augroup("kickstart-lsp-attach", { clear = true }),
- callback = function(event)
- local map = function(keys, func, desc, mode)
- mode = mode or "n"
- vim.keymap.set(mode, keys, func, { buffer = event.buf, desc = "LSP: " .. desc })
- end
-
- -- Jump to the definition of the word under your cursor.
- -- This is where a variable was first declared, or where a function is defined, etc.
- -- To jump back, press <C-t>.
- map("gd", require("fzf-lua").lsp_definitions, "Goto Definition")
-
- map("gk", function()
- vim.diagnostic.open_float()
- end, "Open floating diagnostic")
-
- -- Find references for the word under your cursor.
- map("gr", require("fzf-lua").lsp_references, "Goto References")
-
- -- Jump to the implementation of the word under your cursor.
- -- Useful when your language has ways of declaring types without an actual implementation.
- map("gI", require("fzf-lua").lsp_implementations, "Goto Implementation")
-
- -- Jump to the type of the word under your cursor.
- -- Useful when you're not sure what type a variable is and you want to see
- -- the definition of its *type*, not where it was *defined*.
- map("<leader>D", require("fzf-lua").lsp_typedefs, "Type Definition")
-
- -- Fuzzy find all the symbols in your current document.
- -- Symbols are things like variables, functions, types, etc.
- map("<leader>ds", require("fzf-lua").lsp_document_symbols, "Document Symbols")
-
- -- Fuzzy find all the symbols in your current workspace.
- -- Similar to document symbols, except searches over your entire project.
- map("<leader>ws", require("fzf-lua").lsp_live_workspace_symbols, "Workspace Symbols")
-
- -- Rename the variable under your cursor.
- -- Most Language Servers support renaming across files, etc.
- map("gR", vim.lsp.buf.rename, "Rename")
-
- -- Execute a code action, usually your cursor needs to be on top of an error
- -- or a suggestion from your LSP for this to activate.
- map("<leader>ca", vim.lsp.buf.code_action, "Code Action", { "n", "x" })
-
- -- WARN: This is not Goto Definition, this is Goto Declaration.
- -- For example, in C this would take you to the header.
- map("gD", vim.lsp.buf.declaration, "Goto Declaration")
- local function client_supports_method(client, method, bufnr)
- if vim.fn.has("nvim-0.11") == 1 then
- return client:supports_method(method, bufnr)
- else
- return client.supports_method(method, { bufnr = bufnr })
- end
- end
-
- -- The following two autocommands are used to highlight references of the
- -- word under your cursor when your cursor rests there for a little while.
- -- See `:help CursorHold` for information about when this is executed
- --
- -- When you move your cursor, the highlights will be cleared (the second autocommand).
- local client = vim.lsp.get_client_by_id(event.data.client_id)
- if
- client
- and client_supports_method(client, vim.lsp.protocol.Methods.textDocument_documentHighlight, event.buf)
- then
- local highlight_augroup = vim.api.nvim_create_augroup("kickstart-lsp-highlight", { clear = false })
- vim.api.nvim_create_autocmd({ "CursorHold", "CursorHoldI" }, {
- buffer = event.buf,
- group = highlight_augroup,
- callback = vim.lsp.buf.document_highlight,
- })
-
- vim.api.nvim_create_autocmd({ "CursorMoved", "CursorMovedI" }, {
- buffer = event.buf,
- group = highlight_augroup,
- callback = vim.lsp.buf.clear_references,
- })
-
- vim.api.nvim_create_autocmd("LspDetach", {
- group = vim.api.nvim_create_augroup("kickstart-lsp-detach", { clear = true }),
- callback = function(event2)
- vim.lsp.buf.clear_references()
- vim.api.nvim_clear_autocmds({ group = "kickstart-lsp-highlight", buffer = event2.buf })
- end,
- })
- end
-
- -- The following code creates a keymap to toggle inlay hints in your
- -- code, if the language server you are using supports them
- --
- vim.api.nvim_set_hl(0, "LspInlayHint", { fg = "#4c566a", bg = "NONE", italic = true })
-
- -- This may be unwanted, since they displace some of your code
- if client and client_supports_method(client, vim.lsp.protocol.Methods.textDocument_inlayHint, event.buf) then
- map("<leader>th", function()
- vim.lsp.inlay_hint.enable(not vim.lsp.inlay_hint.is_enabled({ bufnr = event.buf }))
- end, "Toggle Inlay Hints")
- end
- end,
- })
-
- vim.keymap.set("n", "gK", function()
- local new_config = not vim.diagnostic.config().virtual_lines
- vim.diagnostic.config({ virtual_lines = new_config })
- end, { desc = "Toggle diagnostic virtual_lines" })
-
- -- Diagnostic Config
- -- See :help vim.diagnostic.Opts
- vim.diagnostic.config({
- severity_sort = true,
- float = { border = "rounded", source = "if_many" },
- underline = { severity = vim.diagnostic.severity.ERROR },
- signs = {
- text = {
- [vim.diagnostic.severity.ERROR] = "󰅚 ",
- [vim.diagnostic.severity.WARN] = "󰀪 ",
- [vim.diagnostic.severity.INFO] = "󰋽 ",
- [vim.diagnostic.severity.HINT] = "󰌶 ",
- },
- },
- virtual_text = {
- source = "if_many",
- spacing = 2,
- },
- update_in_insert = true,
- virtual_lines = false,
- -- virtual_text = {
- -- source = "if_many",
- -- spacing = 2,
- -- format = function(diagnostic)
- -- local diagnostic_message = {
- -- [vim.diagnostic.severity.ERROR] = diagnostic.message,
- -- [vim.diagnostic.severity.WARN] = diagnostic.message,
- -- [vim.diagnostic.severity.INFO] = diagnostic.message,
- -- [vim.diagnostic.severity.HINT] = diagnostic.message,
- -- }
- -- return diagnostic_message[diagnostic.severity]
- -- end,
- -- },
- })
- local original_capabilities = vim.lsp.protocol.make_client_capabilities()
- local capabilities = require("blink.cmp").get_lsp_capabilities(original_capabilities)
- -- Enable the following language servers
- -- Feel free to add/remove any LSPs that you want here. They will automatically be installed.
- --
- -- Add any additional override configuration in the following tables. Available keys are:
- -- - cmd (table): Override the default command used to start the server
- -- - filetypes (table): Override the default list of associated filetypes for the server
- -- - capabilities (table): Override fields in capabilities. Can be used to disable certain LSP features.
- -- - settings (table): Override the default settings passed when initializing the server.
- -- For example, to see the options for `lua_ls`, you could go to: https://luals.github.io/wiki/settings/
- local lspconfig_util = require("lspconfig.util")
- local servers = {
- bashls = {},
- marksman = {},
- pyright = {
- settings = {
- python = {
- analysis = {
- typeCheckingMode = "basic",
- autoSearchPaths = true,
- useLibraryCodeForTypes = true,
- },
- },
- },
- },
- clangd = {
- cmd = {
- "clangd",
- "--fallback-style={BasedOnStyle: LLVM, IndentWidth: 4, TabWidth: 4, UseTab: Never}",
- },
- },
- rust_analyzer = {
- single_file_support = true,
- root_dir = function(fname)
- return lspconfig_util.root_pattern("Cargo.toml", "rust-project.json", ".git")(fname)
- or vim.fs.dirname(fname)
- end,
- },
- lua_ls = {},
- } -- Ensure the servers and tools above are installed
- --
- -- To check the current status of installed tools and/or manually install
- -- other tools, you can run
- -- :Mason
- --
- -- You can press `g?` for help in this menu.
- --
- -- `mason` had to be setup earlier: to configure its options see the
- -- `dependencies` table for `nvim-lspconfig` above.
- --
- -- You can add other tools here that you want Mason to install
- -- for you, so that they are available from within Neovim.
- local ensure_installed = vim.tbl_keys(servers or {})
- vim.list_extend(ensure_installed, {
- "stylua",
- "prettierd",
- })
- require("mason-tool-installer").setup({ ensure_installed = ensure_installed })
-
- require("mason-lspconfig").setup({
- ensure_installed = {}, -- explicitly set to an empty table (Kickstart populates installs via mason-tool-installer)
- automatic_installation = false,
- automatic_enable = false,
- handlers = {
- function(server_name)
- if server_name == "rust_analyzer" then
- return
- end
- local server = servers[server_name] or {}
- -- This handles overriding only values explicitly passed
- -- by the server configuration above. Useful when disabling
- -- certain features of an LSP (for example, turning off formatting for ts_ls)
- server.capabilities = vim.tbl_deep_extend("force", {}, capabilities, server.capabilities or {})
- require("lspconfig")[server_name].setup(server)
- end,
- },
- })
- end,
-}
diff --git a/.config/nvim/lua/config/plugins/lualine.lua b/.config/nvim/lua/config/plugins/lualine.lua
deleted file mode 100644
index 466d7b4..0000000
--- a/.config/nvim/lua/config/plugins/lualine.lua
+++ /dev/null
@@ -1,218 +0,0 @@
-return {
- "nvim-lualine/lualine.nvim",
- event = "VeryLazy",
- dependencies = { "nvim-tree/nvim-web-devicons" },
- -- Eviline config for lualine
- -- Author: shadmansaleh
- -- Credit: glepnir
- config = function()
- local lualine = require("lualine")
-
- -- Color table for highlights
- -- stylua: ignore
- local colors = {
- bg = '#434c5e',
- fg = '#d8dee9',
- yellow = '#ebcb8b',
- cyan = '#88c0d0',
- darkblue = '#5e81ac',
- green = '#a3be8c',
- orange = '#d08770',
- violet = '#b48ead',
- blue = '#81a1c1',
- red = '#bf616a',
- }
-
- local conditions = {
- buffer_not_empty = function()
- return vim.fn.empty(vim.fn.expand("%:t")) ~= 1
- end,
- hide_in_width = function()
- return vim.fn.winwidth(0) > 80
- end,
- check_git_workspace = function()
- local filepath = vim.fn.expand("%:p:h")
- local gitdir = vim.fn.finddir(".git", filepath .. ";")
- return gitdir and #gitdir > 0 and #gitdir < #filepath
- end,
- }
-
- local config = {
- options = {
- component_separators = "",
- section_separators = "",
- theme = {
- normal = { c = { fg = colors.fg, bg = colors.bg } },
- inactive = { c = { fg = colors.fg, bg = colors.bg } },
- },
- },
- sections = {
- lualine_a = {},
- lualine_b = {},
- lualine_y = {},
- lualine_z = {},
- lualine_c = {},
- lualine_x = {},
- },
- inactive_sections = {
- lualine_a = {},
- lualine_b = {},
- lualine_y = {},
- lualine_z = {},
- lualine_c = {},
- lualine_x = {},
- },
- }
-
- -- Inserts a component in lualine_c at left section
- local function ins_left(component)
- table.insert(config.sections.lualine_c, component)
- end
-
- -- Inserts a component in lualine_x at right section
- local function ins_right(component)
- table.insert(config.sections.lualine_x, component)
- end
-
- -- ins_left({
- -- function()
- -- return "▊"
- -- end,
- -- color = { fg = colors.blue }, -- Sets highlighting of component
- -- padding = { left = 0, right = 1 }, -- We don't need space before this
- -- })
-
- ins_left({
- -- mode component
- function()
- return "  " .. string.upper(vim.fn.mode())
- end,
- color = function()
- -- auto change color according to neovims mode
- local mode_color = {
- n = colors.red,
- i = colors.green,
- v = colors.blue,
- [""] = colors.blue,
- V = colors.blue,
- c = colors.violet,
- no = colors.red,
- s = colors.orange,
- S = colors.orange,
- [""] = colors.orange,
- ic = colors.yellow,
- R = colors.violet,
- Rv = colors.violet,
- cv = colors.red,
- ce = colors.red,
- r = colors.cyan,
- rm = colors.cyan,
- ["r?"] = colors.cyan,
- ["!"] = colors.red,
- t = colors.red,
- }
- return { fg = mode_color[vim.fn.mode()] }
- end,
- padding = { right = 1 },
- })
-
- ins_left({
- "filename",
- cond = conditions.buffer_not_empty,
- color = { fg = colors.green, gui = "bold" },
- })
- ins_left({
- "filesize",
- cond = conditions.buffer_not_empty,
- })
-
- ins_right({ "location" })
-
- ins_right({ "progress", color = { fg = colors.fg, gui = "bold" } })
-
- ins_left({
- "diagnostics",
- sources = { "nvim_diagnostic" },
- symbols = { error = " ", warn = " ", info = " " },
- diagnostics_color = {
- error = { fg = colors.red },
- warn = { fg = colors.yellow },
- info = { fg = colors.cyan },
- },
- })
- --
- -- -- Insert mid section. You can make any number of sections in neovim :)
- -- -- for lualine it's any number greater then 2
- -- ins_left({
- -- function()
- -- return "%="
- -- end,
- -- })
- --
- -- ins_left({
- -- -- Lsp server name .
- -- function()
- -- local msg = "No Active Lsp"
- -- local buf_ft = vim.api.nvim_get_option_value("filetype", { buf = 0 })
- -- local clients = vim.lsp.get_clients()
- -- if next(clients) == nil then
- -- return msg
- -- end
- -- for _, client in ipairs(clients) do
- -- local filetypes = client.config.filetypes
- -- if filetypes and vim.fn.index(filetypes, buf_ft) ~= -1 then
- -- return client.name
- -- end
- -- end
- -- return msg
- -- end,
- -- icon = " LSP:",
- -- color = { fg = "#ffffff", gui = "bold" },
- -- })
-
- -- ins_right({
- -- "filetype",
- -- color = { fg = colors.fg, gui = "bold" },
- -- })
- -- -- Add components to right sections
- -- ins_right({
- -- "o:encoding", -- option component same as &encoding in viml
- -- fmt = string.upper, -- I'm not sure why it's upper case either ;)
- -- cond = conditions.hide_in_width,
- -- color = { fg = colors.green, gui = "bold" },
- -- })
- --
- -- ins_right({
- -- "fileformat",
- -- fmt = string.upper,
- -- color = { fg = colors.green, gui = "bold" },
- -- })
-
- -- ins_right({
- -- "branch",
- -- icon = "",
- -- color = { fg = colors.violet, gui = "bold" },
- -- })
-
- -- ins_right({
- -- "diff",
- -- symbols = { added = " ", modified = " ", removed = " " },
- -- diff_color = {
- -- added = { fg = colors.green },
- -- modified = { fg = colors.orange },
- -- removed = { fg = colors.red },
- -- },
- -- cond = conditions.hide_in_width,
- -- })
-
- -- ins_right({
- -- function()
- -- return "▊"
- -- end,
- -- color = { fg = colors.blue },
- -- padding = { left = 1 },
- -- })
-
- lualine.setup(config)
- end,
-}
diff --git a/.config/nvim/lua/config/plugins/luasnip.lua b/.config/nvim/lua/config/plugins/luasnip.lua
deleted file mode 100644
index a051cee..0000000
--- a/.config/nvim/lua/config/plugins/luasnip.lua
+++ /dev/null
@@ -1,21 +0,0 @@
-return {
- "L3MON4D3/LuaSnip",
- version = "v2.*",
- event = "VeryLazy",
- build = "make install_jsregexp",
- config = function()
- require("luasnip.loaders.from_lua").load({ paths = "~/.config/nvim/lua/config/snippets/" })
- local ls = require("luasnip")
- vim.keymap.set({ "i", "s" }, "<C-d>", function()
- ls.jump(1)
- end, { silent = true })
- vim.keymap.set({ "i", "s" }, "<C-u>", function()
- ls.jump(-1)
- end, { silent = true })
- ls.config.setup({
- enable_autosnippets = true,
- region_check_events = "InsertEnter",
- delete_check_events = "InsertLeave",
- })
- end,
-}
diff --git a/.config/nvim/lua/config/plugins/markdown.lua b/.config/nvim/lua/config/plugins/markdown.lua
deleted file mode 100644
index 223d3fb..0000000
--- a/.config/nvim/lua/config/plugins/markdown.lua
+++ /dev/null
@@ -1,220 +0,0 @@
-return {
- {
- "bullets-vim/bullets.vim",
- ft = "markdown",
- config = function()
- vim.g.bullets_delete_last_bullet_if_empty = 1
- end,
- },
- {
- "stevearc/conform.nvim",
- event = "VeryLazy",
- optional = true,
- opts = {
- formatters = {
- ["markdownlint-cli2"] = {
- condition = function(_, ctx)
- local diag = vim.tbl_filter(function(d)
- return d.source == "markdownlint"
- end, vim.diagnostic.get(ctx.buf))
- return #diag > 0
- end,
- },
- },
- formatters_by_ft = {
- ["markdown"] = { "prettier", "markdownlint-cli2" },
- ["markdown.mdx"] = { "prettier", "markdownlint-cli2" },
- },
- },
- },
- {
- "williamboman/mason.nvim",
- event = "VeryLazy",
- opts = { ensure_installed = { "markdownlint-cli2" } },
- },
- {
- "nvimtools/none-ls.nvim",
- event = "VeryLazy",
- optional = true,
- opts = function(_, opts)
- local nls = require("null-ls")
- opts.sources = vim.list_extend(opts.sources or {}, {
- nls.builtins.diagnostics.markdownlint_cli2,
- })
- end,
- },
- {
- "mfussenegger/nvim-lint",
- event = "VeryLazy",
-
- optional = true,
- opts = {
- linters_by_ft = {
- markdown = { "markdownlint-cli2" },
- },
- },
- },
- {
- "neovim/nvim-lspconfig",
- event = "VeryLazy",
-
- opts = {
- servers = {
- marksman = {},
- },
- },
- },
-
- {
- "iamcco/markdown-preview.nvim",
- event = "VeryLazy",
-
- cmd = { "MarkdownPreviewToggle", "MarkdownPreview", "MarkdownPreviewStop" },
- build = function()
- require("lazy").load({ plugins = { "markdown-preview.nvim" } })
- vim.fn["mkdp#util#install"]()
- end,
- keys = {
- {
- "<leader>ow",
- ft = "markdown",
- "<cmd>MarkdownPreviewToggle<cr>",
- desc = "Markdown Preview",
- },
- },
- config = function()
- vim.cmd([[do FileType]])
- end,
- },
-
- {
- "MeanderingProgrammer/render-markdown.nvim",
- ft = "markdown",
- config = function()
- require("render-markdown").setup({
- win_options = {
- conceallevel = {
- default = 0, -- Set default conceallevel to 0
- rendered = 3, -- Keep rendered mode at 3
- },
- },
- bullet = {
- -- Turn on / off list bullet rendering
- enabled = true,
- },
- latex = { enabled = false },
- checkbox = {
- -- Turn on / off checkbox state rendering
- enabled = true,
- -- Determines how icons fill the available space:
- -- inline: underlying text is concealed resulting in a left aligned icon
- -- overlay: result is left padded with spaces to hide any additional text
- position = "inline",
- unchecked = {
- -- Replaces '[ ]' of 'task_list_marker_unchecked'
- icon = " 󰄱 ",
- -- Highlight for the unchecked icon
- highlight = "RenderMarkdownUnchecked",
- -- Highlight for item associated with unchecked checkbox
- scope_highlight = nil,
- },
- checked = {
- -- Replaces '[x]' of 'task_list_marker_checked'
- icon = " 󰱒 ",
- -- Highlight for the checked icon
- highlight = "RenderMarkdownChecked",
- -- Highlight for item associated with checked checkbox
- scope_highlight = nil,
- },
- },
- html = {
- -- Turn on / off all HTML rendering
- enabled = true,
- comment = {
- -- Turn on / off HTML comment concealing
- conceal = false,
- },
- },
- heading = {
- -- left_pad = 1,
- sign = false,
- icons = { " 󰎤 ", " 󰎧 ", " 󰎪 ", " 󰎭 ", " 󰎱 ", " 󰎳 " },
- backgrounds = {
- "Headline1Bg",
- "Headline2Bg",
- "Headline3Bg",
- "Headline4Bg",
- "Headline5Bg",
- "Headline6Bg",
- },
- foregrounds = {
- "Headline1Fg",
- "Headline2Fg",
- "Headline3Fg",
- "Headline4Fg",
- "Headline5Fg",
- "Headline6Fg",
- },
- },
- ft = { "markdown" },
- })
-
- local color1_bg = "#bf616a"
- local color2_bg = "#d08770"
- local color5_bg = "#5e81ac"
- local color4_bg = "#a3be8c"
- local color6_bg = "#b48ead"
- local color3_bg = "#ebcb8b"
- local color_fg = "#2e3440"
-
- vim.cmd(string.format([[highlight @markup.strong guifg=%s]], color2_bg))
- vim.cmd(string.format([[highlight @markup.italic guifg=%s]], color2_bg))
- vim.cmd(string.format([[highlight RenderMarkdownCodeInline guifg=%s]], color4_bg))
-
- -- Heading background color highlights
- vim.cmd(string.format([[highlight Headline1Bg guifg=%s guibg=%s]], color_fg, color1_bg))
- vim.cmd(string.format([[highlight Headline2Bg guifg=%s guibg=%s]], color_fg, color2_bg))
- vim.cmd(string.format([[highlight Headline3Bg guifg=%s guibg=%s]], color_fg, color3_bg))
- vim.cmd(string.format([[highlight Headline4Bg guifg=%s guibg=%s]], color_fg, color4_bg))
- vim.cmd(string.format([[highlight Headline5Bg guifg=%s guibg=%s]], color_fg, color5_bg))
- vim.cmd(string.format([[highlight Headline6Bg guifg=%s guibg=%s]], color_fg, color6_bg))
-
- -- Heading foreground color highlights (bold and with specific colors)
- vim.cmd(string.format([[highlight Headline1Fg cterm=bold gui=bold guifg=%s]], color1_bg))
- vim.cmd(string.format([[highlight Headline2Fg cterm=bold gui=bold guifg=%s]], color2_bg))
- vim.cmd(string.format([[highlight Headline3Fg cterm=bold gui=bold guifg=%s]], color3_bg))
- vim.cmd(string.format([[highlight Headline4Fg cterm=bold gui=bold guifg=%s]], color4_bg))
- vim.cmd(string.format([[highlight Headline5Fg cterm=bold gui=bold guifg=%s]], color5_bg))
- vim.cmd(string.format([[highlight Headline6Fg cterm=bold gui=bold guifg=%s]], color6_bg))
-
- vim.cmd(string.format([[highlight RenderMarkdownH1Bg guifg=%s guibg=%s]], color_fg, color1_bg))
- vim.cmd(string.format([[highlight RenderMarkdownH2Bg guifg=%s guibg=%s]], color_fg, color2_bg))
- vim.cmd(string.format([[highlight RenderMarkdownH3Bg guifg=%s guibg=%s]], color_fg, color3_bg))
- vim.cmd(string.format([[highlight RenderMarkdownH4Bg guifg=%s guibg=%s]], color_fg, color4_bg))
- vim.cmd(string.format([[highlight RenderMarkdownH5Bg guifg=%s guibg=%s]], color_fg, color5_bg))
- vim.cmd(string.format([[highlight RenderMarkdownH6Bg guifg=%s guibg=%s]], color_fg, color6_bg))
-
- -- Apply custom foreground colors for headings (bold)
- vim.cmd(string.format([[highlight RenderMarkdownH1 guifg=%s guibg=%s cterm=bold gui=bold]], color1_bg, color_fg))
- vim.cmd(string.format([[highlight RenderMarkdownH2 guifg=%s guibg=%s cterm=bold gui=bold]], color2_bg, color_fg))
- vim.cmd(string.format([[highlight RenderMarkdownH3 guifg=%s guibg=%s cterm=bold gui=bold]], color3_bg, color_fg))
- vim.cmd(string.format([[highlight RenderMarkdownH4 guifg=%s guibg=%s cterm=bold gui=bold]], color4_bg, color_fg))
- vim.cmd(string.format([[highlight RenderMarkdownH5 guifg=%s guibg=%s cterm=bold gui=bold]], color5_bg, color_fg))
- vim.cmd(string.format([[highlight RenderMarkdownH6 guifg=%s guibg=%s cterm=bold gui=bold]], color6_bg, color_fg))
- Snacks.toggle({
- name = "Render Markdown",
- get = function()
- return require("render-markdown.state").enabled
- end,
- set = function(enabled)
- local m = require("render-markdown")
- if enabled then
- m.enable()
- else
- m.disable()
- end
- end,
- }):map("<leader>or", { desc = "Toggle Render Markdown" })
- end,
- },
-}
diff --git a/.config/nvim/lua/config/plugins/mini.lua b/.config/nvim/lua/config/plugins/mini.lua
deleted file mode 100644
index fe6a3aa..0000000
--- a/.config/nvim/lua/config/plugins/mini.lua
+++ /dev/null
@@ -1,27 +0,0 @@
-return {
- {
- "echasnovski/mini.nvim",
- event = "VeryLazy",
- enabled = true,
- config = function()
- require("mini.icons").setup()
- require("mini.move").setup()
- require("mini.ai").setup()
- require("mini.surround").setup()
- require("mini.pairs").setup()
- --
- -- HACK: The Key Commands -> for help run ;h nvim-surround.usage
- --
- -- Old text Command New text
- -- --------------------------------------------------------------------------------
- -- surr*ound_words ysiw) (surround_words)
- -- *make strings ys$" "make strings"
- -- [delete ar*ound me!] ds] delete around me!
- -- remove <b>HTML t*ags</b> dst remove HTML tags
- -- 'change quot*es' cs'" "change quotes"
- -- <b>or tag* types</b> csth1<CR> <h1>or tag types</h1>
- -- delete(functi*on calls) dsf function calls
- --
- end,
- },
-}
diff --git a/.config/nvim/lua/config/plugins/neotree.lua b/.config/nvim/lua/config/plugins/neotree.lua
deleted file mode 100644
index 11a0a98..0000000
--- a/.config/nvim/lua/config/plugins/neotree.lua
+++ /dev/null
@@ -1,17 +0,0 @@
-return {
- {
- "nvim-neo-tree/neo-tree.nvim",
- branch = "v3.x",
- dependencies = {
- "nvim-lua/plenary.nvim",
- "MunifTanjim/nui.nvim",
- "nvim-tree/nvim-web-devicons", -- optional, but recommended
- },
- lazy = false, -- neo-tree will lazily load itself
- opts = {
- window = {
- position = "right",
- },
- },
- },
-}
diff --git a/.config/nvim/lua/config/plugins/oil.lua b/.config/nvim/lua/config/plugins/oil.lua
deleted file mode 100644
index 555768f..0000000
--- a/.config/nvim/lua/config/plugins/oil.lua
+++ /dev/null
@@ -1,37 +0,0 @@
-return {
- "stevearc/oil.nvim",
- dependencies = { "nvim-tree/nvim-web-devicons" },
- config = function()
- require("oil").setup({
- default_file_explorer = true,
- keymaps = {
- ["l"] = "actions.select",
- ["h"] = "actions.parent",
- ["<CR>"] = "actions.select",
- ["<C-s>"] = nil,
- ["<C-h>"] = nil,
- ["<C-l>"] = nil,
- },
- delete_to_trash = true,
- view_options = {
- show_hidden = true,
- },
- skip_confirm_for_simple_edits = true,
- float = {
- max_width = 80,
- max_height = 30,
- override = function(conf)
- return conf
- end,
- },
- })
- vim.keymap.set("n", "-", "<CMD>Oil<CR>", { desc = "Open parent directory" })
-
- vim.api.nvim_create_autocmd("FileType", {
- pattern = "oil",
- callback = function()
- vim.opt_local.cursorline = true
- end,
- })
- end,
-}
diff --git a/.config/nvim/lua/config/plugins/rustacean.lua b/.config/nvim/lua/config/plugins/rustacean.lua
deleted file mode 100644
index 1187aad..0000000
--- a/.config/nvim/lua/config/plugins/rustacean.lua
+++ /dev/null
@@ -1,29 +0,0 @@
-return {
- "mrcjkb/rustaceanvim",
- version = "^8", -- Recommended
- lazy = false, -- This plugin is already lazy
- init = function()
- local capabilities = vim.lsp.protocol.make_client_capabilities()
- local ok, blink = pcall(require, "blink.cmp")
- if ok then
- capabilities = blink.get_lsp_capabilities(capabilities)
- end
-
- vim.g.rustaceanvim = {
- tools = {
- enable_clippy = false,
- },
- server = {
- capabilities = capabilities,
- standalone = true,
- status_notify_level = false,
- load_vscode_settings = false,
- default_settings = {
- ["rust-analyzer"] = {
- checkOnSave = false,
- },
- },
- },
- }
- end,
-}
diff --git a/.config/nvim/lua/config/plugins/snacks.lua b/.config/nvim/lua/config/plugins/snacks.lua
deleted file mode 100644
index dd731dd..0000000
--- a/.config/nvim/lua/config/plugins/snacks.lua
+++ /dev/null
@@ -1,84 +0,0 @@
-return {
- "folke/snacks.nvim",
- priority = 1000,
- lazy = false,
- opts = {
- bigfile = { enabled = true },
- notifier = { timeout = 2000 },
- quickfile = { enabled = true },
- statuscolumn = { enabled = true },
- image = {
- enabled = true,
- doc = {
- enabled = true,
- float = true,
- inline = false,
- max_width = 60,
- max_height = 30,
- },
- },
- dashboard = {
- enabled = true,
- autokeys = "wert",
- preset = {
- keys = {
- { icon = " ", key = "f", desc = "Find File", action = ":lua Snacks.dashboard.pick('files')" },
- { icon = " ", key = "g", desc = "Grep", action = ":lua Snacks.dashboard.pick('live_grep')", padding = 1 },
- { icon = " ", key = "n", desc = "New File", action = ":ene | startinsert" },
- { icon = " ", key = "c", desc = "LeetCode", action = ":Leet" },
- { icon = "󰒲 ", key = "l", desc = "Lazy", action = ":Lazy", enabled = package.loaded.lazy ~= nil },
- { icon = " ", key = "q", desc = "Quit", action = ":qa" },
- },
- },
- formats = {
- key = function(item)
- return { { "[", hl = "special" }, { item.key, hl = "key" }, { "]", hl = "special" } }
- end,
- },
- sections = {
- { section = "recent_files", limit = 4, padding = 1 },
- { section = "keys", padding = 1 },
- { section = "startup" },
- },
- },
- styles = {
- snacks_image = {
- relative = "editor",
- col = -1,
- },
- lazygit = {
- wo = {
- winhighlight = "NormalFloat:None,FloatBorder:SnacksInputBorder,FloatTitle:SnacksInputTitle",
- cursorline = false,
- },
- },
- float = {
- backdrop = false,
- },
- blame_line = {
- backdrop = false,
- },
- },
- },
- init = function()
- vim.api.nvim_create_autocmd("User", {
- pattern = "VeryLazy",
- callback = function()
- _G.dd = function(...)
- Snacks.debug.inspect(...)
- end
- _G.bt = function()
- Snacks.debug.backtrace()
- end
- vim.print = _G.dd
- Snacks.toggle.option("spell", { name = "Spelling" }):map("<leader>ts")
- Snacks.toggle.option("wrap", { name = "Wrap" }):map("<leader>tw")
- Snacks.toggle.diagnostics():map("<leader>td")
- Snacks.toggle
- .option("conceallevel", { off = 0, on = vim.o.conceallevel > 0 and vim.o.conceallevel or 2 })
- :map("<leader>tc")
- Snacks.toggle.indent():map("<leader>ti")
- end,
- })
- end,
-}
diff --git a/.config/nvim/lua/config/plugins/treesitter.lua b/.config/nvim/lua/config/plugins/treesitter.lua
deleted file mode 100644
index 3e866c5..0000000
--- a/.config/nvim/lua/config/plugins/treesitter.lua
+++ /dev/null
@@ -1,43 +0,0 @@
-return {
- {
- "nvim-treesitter/nvim-treesitter",
- event = "VeryLazy",
- opts = {
- ensure_installed = {
- "c",
- "lua",
- "vim",
- "vimdoc",
- "query",
- "markdown",
- "markdown_inline",
- "rust",
- "css",
- "javascript",
- "svelte",
- "tsx",
- "typst",
- },
- auto_install = true,
- incremental_selection = {
- enable = true,
- keymaps = {
- node_incremental = "<Enter>",
- scope_incremental = false,
- node_decremental = "<Backspace>",
- },
- },
- highlight = {
- enable = true,
- disable = function(lang, buf)
- local max_filesize = 100 * 1024 -- 100 KB
- local ok, stats = pcall(vim.loop.fs_stat, vim.api.nvim_buf_get_name(buf))
- if ok and stats and stats.size > max_filesize then
- return true
- end
- end,
- additional_vim_regex_highlighting = false,
- },
- },
- },
-}
diff --git a/.config/nvim/lua/config/plugins/typst.lua b/.config/nvim/lua/config/plugins/typst.lua
deleted file mode 100644
index 2443773..0000000
--- a/.config/nvim/lua/config/plugins/typst.lua
+++ /dev/null
@@ -1,9 +0,0 @@
-return {
- "chomosuke/typst-preview.nvim",
- -- lazy = false, -- or ft = 'typst'
- ft = "typst",
- version = "1.*",
- opts = {
- invert_colors = "auto",
- }, -- lazy.nvim will implicitly calls `setup {}`
-}
diff --git a/.config/nvim/lua/config/plugins/utils.lua b/.config/nvim/lua/config/plugins/utils.lua
deleted file mode 100644
index 273de1a..0000000
--- a/.config/nvim/lua/config/plugins/utils.lua
+++ /dev/null
@@ -1,58 +0,0 @@
-return {
- {
- "ojroques/nvim-osc52",
- event = "VeryLazy",
- config = function()
- vim.keymap.set("v", "Y", require("osc52").copy_visual)
- end,
- },
- { -- For CSS colors
- "NvChad/nvim-colorizer.lua",
- event = "BufReadPre",
- opts = {
- user_default_options = {
- names = false,
- tailwind = "both",
- css = true,
- css_fn = true,
- mode = "background",
- },
- },
- },
- { -- for file outline
- "hedyhli/outline.nvim",
- event = "VeryLazy",
- opts = {},
- },
- { -- Undotree
- "mbbill/undotree",
- event = "VeryLazy",
- config = function()
- vim.g.undotree_SplitWidth = 50
- vim.g.undotree_WindowLayout = 3
- end,
- },
- { -- for colored brackets and divs
- "HiPhish/rainbow-delimiters.nvim",
- event = "VeryLazy",
- },
- { -- for tmux navigation
- event = "VeryLazy",
- "christoomey/vim-tmux-navigator",
- cmd = {
- "TmuxNavigateLeft",
- "TmuxNavigateDown",
- "TmuxNavigateUp",
- "TmuxNavigateRight",
- "TmuxNavigatePrevious",
- "TmuxNavigatorProcessList",
- },
- keys = {
- { "<c-h>", "<cmd><C-U>TmuxNavigateLeft<cr>" },
- { "<c-j>", "<cmd><C-U>TmuxNavigateDown<cr>" },
- { "<c-k>", "<cmd><C-U>TmuxNavigateUp<cr>" },
- { "<c-l>", "<cmd><C-U>TmuxNavigateRight<cr>" },
- { "<c-\\>", "<cmd><C-U>TmuxNavigatePrevious<cr>" },
- },
- },
-}
diff --git a/.config/nvim/lua/config/plugins/uv.lua b/.config/nvim/lua/config/plugins/uv.lua
deleted file mode 100644
index 121921b..0000000
--- a/.config/nvim/lua/config/plugins/uv.lua
+++ /dev/null
@@ -1,7 +0,0 @@
-return {
- "benomahony/uv.nvim",
- event = "VeryLazy",
- opts = {
- picker_integration = true,
- },
-}
diff --git a/.config/nvim/lua/config/plugins/which-key.lua b/.config/nvim/lua/config/plugins/which-key.lua
deleted file mode 100644
index 9e97f9f..0000000
--- a/.config/nvim/lua/config/plugins/which-key.lua
+++ /dev/null
@@ -1,27 +0,0 @@
-return {
- "folke/which-key.nvim",
- event = "VeryLazy",
- opts = {
- win = {
- wo = {
- winblend = 0,
- },
- },
- preset = "helix",
- icons = {
- rules = false,
- },
- delay = 500,
- spec = {
- { "<leader>c", group = "Code", mode = { "n", "x" } },
- { "<leader>d", group = "Document" },
- { "<leader>g", group = "Git" },
- { "<leader>m", group = "Marks" },
- { "<leader>r", group = "Rename" },
- { "<leader>s", group = "Search" },
- { "<leader>t", group = "Toggle" },
- { "<leader>w", group = "Workspace" },
- { "<leader>l", group = "LSP" },
- },
- },
-}
diff --git a/.config/nvim/lua/config/snippets/all.lua b/.config/nvim/lua/config/snippets/all.lua
deleted file mode 100644
index e2a2ef1..0000000
--- a/.config/nvim/lua/config/snippets/all.lua
+++ /dev/null
@@ -1,10 +0,0 @@
-local ls = require("luasnip")
-local s = ls.snippet
-local t = ls.text_node
-local i = ls.insert_node
-
-return {
- s("hi", {
- t("Hello, world!"),
- }),
-}
diff --git a/.config/nvim/lua/mappings.lua b/.config/nvim/lua/mappings.lua
deleted file mode 100644
index 9f17f28..0000000
--- a/.config/nvim/lua/mappings.lua
+++ /dev/null
@@ -1,71 +0,0 @@
-local wk = require("which-key")
-
-vim.keymap.set("n", "x", '"_x', { noremap = true, silent = true })
-vim.keymap.set("x", "x", '"_x', { noremap = true, silent = true })
-vim.keymap.set("v", "x", '"_x', { noremap = true, silent = true })
-vim.keymap.set("n", "c", '"_c')
-vim.keymap.set("n", "C", '"_C')
-vim.keymap.set("n", "cc", '"_cc')
-vim.keymap.set("x", "c", '"_c')
-
-local fzf = require("fzf-lua")
-
-wk.add({
- {
- mode = { "n" },
- { "<leader>qr", "<cmd>Leet run<CR>", desc = "Run code" },
- { "<leader>qs", "<cmd>Leet submit<CR>", desc = "Submit code" },
- { "<leader>qi", "<cmd>Leet info<CR>", desc = "Get info" },
- { "<leader>qo", "<cmd>Leet open<CR>", desc = "Open in browser" },
- { "<leader>qd", "<cmd>Leet desc<CR>", desc = "Toggle decription" },
- { "<leader>qm", "<cmd>Leet menu<CR>", desc = "Open menu" },
- { "<C-d>", "<C-d>zz", desc = "Move down in buffer with cursor centered" },
- { "<C-u>", "<C-u>zz", desc = "Move up in buffer with cursor centered" },
- { "n", "nzzzv", desc = "Search next with cursor centered" },
- { "N", "Nzzzv", desc = "Search previous with cursor centered" },
- { "<leader>u", "<cmd>UndotreeToggle<CR>", desc = "Toggle undo tree" },
- { "<leader>o", "<cmd>Outline<CR>", desc = "Toggle Outline" },
- { "<Esc>", "<cmd>nohlsearch<CR>", hidden = true }, -- Unhighlight
- { "<C-h>", "<C-w><C-h>", hidden = true }, -- Move to left window
- { "<C-l>", "<C-w><C-l>", hidden = true }, -- Move to right window
- { "<C-j>", "<C-w><C-j>", hidden = true }, -- Move to lower window
- { "<C-k>", "<C-w><C-k>", hidden = true }, -- Move to upper window
- { "<C-q>", "<C-w><C-q>", hidden = true }, -- Close window
- { "<leader>l", "<cmd>Neotree toggle<CR>", desc = "Neotree toggle" },
- {
- "<leader><leader>",
- function()
- require("fzf-lua").buffers()
- end,
- desc = "Search Buffers",
- },
- {
- "<leader>s",
- function()
- require("fzf-lua").files()
- end,
- desc = "Search Files",
- },
- {
- "<leader>/",
- function()
- require("fzf-lua").live_grep()
- end,
- desc = "Search by Grep",
- },
- {
- "<leader>h",
- function()
- require("fzf-lua").lsp_document_diagnostics()
- end,
- desc = "Search Diagnostics",
- },
- {
- "<leader>n",
- function()
- Snacks.notifier.show_history()
- end,
- desc = "Notification History",
- },
- },
-})
diff --git a/.config/nvim/lua/options.lua b/.config/nvim/lua/options.lua
deleted file mode 100644
index c61f4c9..0000000
--- a/.config/nvim/lua/options.lua
+++ /dev/null
@@ -1,36 +0,0 @@
-local set = vim.opt
-local g = vim.g
-
-g.mapleader = " "
-g.maplocalleader = " "
-g.have_nerd_font = true
-set.number = true
-set.relativenumber = true
-set.termguicolors = true
-set.tabstop = 4
-set.shiftwidth = 4
-set.swapfile = false
-set.expandtab = true
-set.mouse = "a"
-set.showmode = false
-set.breakindent = true
-set.undofile = true
-set.ignorecase = true
-set.smartcase = true
-set.signcolumn = "yes"
-set.updatetime = 250
-set.timeoutlen = 300
-set.splitright = true
-set.splitbelow = true
-set.list = true
-set.listchars = { tab = "» ", trail = "·", nbsp = "␣" }
-set.inccommand = "split"
-set.cursorline = true
-set.scrolloff = 4
-set.sidescrolloff = 4
-set.conceallevel = 2
-set.wrap = false
-
-vim.schedule(function()
- set.clipboard = "unnamedplus"
-end)
diff --git a/.config/nvim/nvim-macos.tar.gz b/.config/nvim/nvim-macos.tar.gz
new file mode 100644
index 0000000..8537307
--- /dev/null
+++ b/.config/nvim/nvim-macos.tar.gz
@@ -0,0 +1 @@
+Not Found \ No newline at end of file
diff --git a/.config/nvim/nvim-pack-lock.json b/.config/nvim/nvim-pack-lock.json
new file mode 100644
index 0000000..9da8e87
--- /dev/null
+++ b/.config/nvim/nvim-pack-lock.json
@@ -0,0 +1,85 @@
+{
+ "plugins": {
+ "LuaSnip": {
+ "rev": "dae4f5aaa3574bd0c2b9dd20fb9542a02c10471c",
+ "src": "https://github.com/L3MON4D3/LuaSnip"
+ },
+ "alpha-nvim": {
+ "rev": "a9d8fb72213c8b461e791409e7feabb74eb6ce73",
+ "src": "https://github.com/goolord/alpha-nvim"
+ },
+ "blink.cmp": {
+ "rev": "4b18c32adef2898f95cdef6192cbd5796c1a332d",
+ "src": "https://github.com/saghen/blink.cmp",
+ "version": "1.0.0 - 2.0.0"
+ },
+ "efmls-configs-nvim": {
+ "rev": "2dd907fe0043b95a901a9aee814f17804aa4426d",
+ "src": "https://github.com/creativenull/efmls-configs-nvim"
+ },
+ "flash.nvim": {
+ "rev": "fcea7ff883235d9024dc41e638f164a450c14ca2",
+ "src": "https://github.com/folke/flash.nvim"
+ },
+ "fzf-lua": {
+ "rev": "b56cd2ffbce57bfd9133a645bd02cd86895a7e3f",
+ "src": "https://www.github.com/ibhagwan/fzf-lua"
+ },
+ "gitsigns.nvim": {
+ "rev": "9f3c6dd7868bcc116e9c1c1929ce063b978fa519",
+ "src": "https://www.github.com/lewis6991/gitsigns.nvim"
+ },
+ "leetcode.nvim": {
+ "rev": "fdd3f91800b3983e27bc9fcfb99cfa7293d7f11a",
+ "src": "https://github.com/kawre/leetcode.nvim"
+ },
+ "mason.nvim": {
+ "rev": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65",
+ "src": "https://github.com/mason-org/mason.nvim"
+ },
+ "mini.nvim": {
+ "rev": "0098de999048af0539183d625c52d733318a441b",
+ "src": "https://www.github.com/echasnovski/mini.nvim"
+ },
+ "nord.nvim": {
+ "rev": "80c1e5321505aeb22b7a9f23eb82f1e193c12470",
+ "src": "https://github.com/shaunsingh/nord.nvim"
+ },
+ "nui.nvim": {
+ "rev": "de740991c12411b663994b2860f1a4fd0937c130",
+ "src": "https://github.com/MunifTanjim/nui.nvim"
+ },
+ "nvim-lspconfig": {
+ "rev": "ead0f5f342d8d323441e7d4b88f0fc436a81ad5f",
+ "src": "https://www.github.com/neovim/nvim-lspconfig"
+ },
+ "nvim-tree.lua": {
+ "rev": "c988e289428d9202b28ba27479647033c7dd2956",
+ "src": "https://www.github.com/nvim-tree/nvim-tree.lua"
+ },
+ "nvim-treesitter": {
+ "rev": "cb2cb74f3c3cbbcc17e79cada2060165d616d849",
+ "src": "https://github.com/nvim-treesitter/nvim-treesitter"
+ },
+ "oil.nvim": {
+ "rev": "0fcc83805ad11cf714a949c98c605ed717e0b83e",
+ "src": "https://github.com/stevearc/oil.nvim"
+ },
+ "outline.nvim": {
+ "rev": "ead1820d49c8e79ce89cab1c2c318981b695c9d2",
+ "src": "https://github.com/hedyhli/outline.nvim"
+ },
+ "plenary.nvim": {
+ "rev": "b9fd5226c2f76c951fc8ed5923d85e4de065e509",
+ "src": "https://github.com/nvim-lua/plenary.nvim"
+ },
+ "rustaceanvim": {
+ "rev": "d50597d482a6f44ddfc54d1af2f69f052053b4de",
+ "src": "https://github.com/mrcjkb/rustaceanvim"
+ },
+ "which-key.nvim": {
+ "rev": "3aab2147e74890957785941f0c1ad87d0a44c15a",
+ "src": "https://github.com/folke/which-key.nvim"
+ }
+ }
+} \ No newline at end of file