From 6a285955c83bd9716ac1f1dcb21ee61358119442 Mon Sep 17 00:00:00 2001 From: hhhh hgfh Date: Sat, 16 May 2026 15:11:20 +0300 Subject: [PATCH] feat: update nvim --- nvim/build_targets.json | 1 - nvim/init.lua | 11 - nvim/lazy-lock.json | 47 -- nvim/lua/configs/bufferline.lua | 64 --- nvim/lua/configs/cmp.lua | 55 -- nvim/lua/configs/conform.lua | 15 - nvim/lua/configs/gitsigns.lua | 53 -- nvim/lua/configs/lazy.lua | 26 - nvim/lua/configs/lsp/e-lspconfig.lua | 55 -- nvim/lua/configs/lsp/lspconfig.lua | 107 ---- nvim/lua/configs/lualine.lua | 54 -- nvim/lua/configs/luasnip.lua | 11 - nvim/lua/configs/nvim-dap.lua | 84 --- nvim/lua/configs/nvimtree.lua | 32 -- nvim/lua/configs/snacks.lua | 0 nvim/lua/configs/telescope.lua | 22 - nvim/lua/configs/treesitter.lua | 46 -- nvim/lua/configs/ufo.lua | 21 - nvim/lua/custom/darcula.lua | 804 --------------------------- nvim/lua/custom/init.lua | 19 - nvim/lua/custom/make.lua | 184 ------ nvim/lua/mappings.lua | 109 ---- nvim/lua/options.lua | 57 -- nvim/lua/plugins/common.lua | 76 --- nvim/lua/plugins/development.lua | 141 ----- nvim/lua/plugins/lines.lua | 17 - nvim/lua/plugins/noice.lua | 30 - nvim/lua/plugins/snacks.lua | 20 - nvim/lua/plugins/telescope.lua | 8 - nvim/lua/plugins/typst.lua | 8 - nvim/lua/plugins/whichkey.lua | 67 --- nvim/stylua.toml | 6 - nvim/temp | 34 -- 33 files changed, 2284 deletions(-) delete mode 100644 nvim/build_targets.json delete mode 100644 nvim/init.lua delete mode 100644 nvim/lazy-lock.json delete mode 100644 nvim/lua/configs/bufferline.lua delete mode 100644 nvim/lua/configs/cmp.lua delete mode 100644 nvim/lua/configs/conform.lua delete mode 100644 nvim/lua/configs/gitsigns.lua delete mode 100644 nvim/lua/configs/lazy.lua delete mode 100644 nvim/lua/configs/lsp/e-lspconfig.lua delete mode 100644 nvim/lua/configs/lsp/lspconfig.lua delete mode 100644 nvim/lua/configs/lualine.lua delete mode 100644 nvim/lua/configs/luasnip.lua delete mode 100644 nvim/lua/configs/nvim-dap.lua delete mode 100644 nvim/lua/configs/nvimtree.lua delete mode 100644 nvim/lua/configs/snacks.lua delete mode 100644 nvim/lua/configs/telescope.lua delete mode 100644 nvim/lua/configs/treesitter.lua delete mode 100644 nvim/lua/configs/ufo.lua delete mode 100644 nvim/lua/custom/darcula.lua delete mode 100644 nvim/lua/custom/init.lua delete mode 100644 nvim/lua/custom/make.lua delete mode 100644 nvim/lua/mappings.lua delete mode 100644 nvim/lua/options.lua delete mode 100644 nvim/lua/plugins/common.lua delete mode 100644 nvim/lua/plugins/development.lua delete mode 100644 nvim/lua/plugins/lines.lua delete mode 100644 nvim/lua/plugins/noice.lua delete mode 100644 nvim/lua/plugins/snacks.lua delete mode 100644 nvim/lua/plugins/telescope.lua delete mode 100644 nvim/lua/plugins/typst.lua delete mode 100644 nvim/lua/plugins/whichkey.lua delete mode 100644 nvim/stylua.toml delete mode 100644 nvim/temp diff --git a/nvim/build_targets.json b/nvim/build_targets.json deleted file mode 100644 index c7a9f2a..0000000 --- a/nvim/build_targets.json +++ /dev/null @@ -1 +0,0 @@ -{"barsic": "cp ~/engine/builddir/pmc2/pmc2-engine bin/.", "build": "meson compile -C builddir pmc2-engine", "test": "meson test -C builddir -v pmc2_tests", "barsic-master": "cp ~/builddir/pmc2/pmc2-engine && make run_alice"} diff --git a/nvim/init.lua b/nvim/init.lua deleted file mode 100644 index dd1640b..0000000 --- a/nvim/init.lua +++ /dev/null @@ -1,11 +0,0 @@ --- Default my settings -vim.g.mapleader = " " -vim.wo.number = true -vim.wo.relativenumber = true -vim.opt.wrap = false - --- Add basic configs -require("configs.lazy") -require("mappings") -require("options") -require("custom.init") diff --git a/nvim/lazy-lock.json b/nvim/lazy-lock.json deleted file mode 100644 index eda26c3..0000000 --- a/nvim/lazy-lock.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "LuaSnip": { "branch": "master", "commit": "dae4f5aaa3574bd0c2b9dd20fb9542a02c10471c" }, - "bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" }, - "cmp-async-path": { "branch": "main", "commit": "f8af3f726e07f2e9d37672eaa9102581aefce149" }, - "cmp-buffer": { "branch": "main", "commit": "b74fab3656eea9de20a9b8116afa3cfc4ec09657" }, - "cmp-nvim-lsp": { "branch": "main", "commit": "cbc7b02bb99fae35cb42f514762b89b5126651ef" }, - "cmp-nvim-lua": { "branch": "main", "commit": "e3a22cb071eb9d6508a156306b102c45cd2d573d" }, - "cmp_luasnip": { "branch": "master", "commit": "98d9cb5c2c38532bd9bdb481067b20fea8f32e90" }, - "conform.nvim": { "branch": "master", "commit": "c2526f1cde528a66e086ab1668e996d162c75f4f" }, - "friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" }, - "git-conflict.nvim": { "branch": "main", "commit": "4bbfdd92d547d2862a75b4e80afaf30e73f7bbb4" }, - "gitsigns.nvim": { "branch": "main", "commit": "1ce96a464fdbc24208e24c117e2021794259005d" }, - "gitui.nvim": { "branch": "main", "commit": "686d74e79899af760ed9f5f0ad2bd1bb1c135e26" }, - "lazy.nvim": { "branch": "main", "commit": "306a05526ada86a7b30af95c5cc81ffba93fef97" }, - "lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" }, - "marks.nvim": { "branch": "master", "commit": "f353e8c08c50f39e99a9ed474172df7eddd89b72" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "ae609525ddf01c153c39305730b1791800ffe4fe" }, - "mason-nvim-dap.nvim": { "branch": "main", "commit": "9a10e096703966335bd5c46c8c875d5b0690dade" }, - "mason.nvim": { "branch": "main", "commit": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65" }, - "mini.nvim": { "branch": "main", "commit": "a995fe9cd4193fb492b5df69175a351a74b3d36b" }, - "mini.pairs": { "branch": "main", "commit": "4089aa6ea6423e02e1a8326a7a7a00159f6f5e04" }, - "neotest": { "branch": "master", "commit": "deadfb1af5ce458742671ad3a013acb9a6b41178" }, - "neotest-gtest": { "branch": "main", "commit": "b66f1d33cbf3b37b9803e6bc7ef47ac60eba86b1" }, - "neotest-phpunit": { "branch": "main", "commit": "2761ae9e9a385e491a9731f8c52824e1be64a68f" }, - "noice.nvim": { "branch": "main", "commit": "7bfd942445fb63089b59f97ca487d605e715f155" }, - "nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" }, - "nvim-autopairs": { "branch": "master", "commit": "59bce2eef357189c3305e25bc6dd2d138c1683f5" }, - "nvim-cmp": { "branch": "main", "commit": "da88697d7f45d16852c6b2769dc52387d1ddc45f" }, - "nvim-dap": { "branch": "master", "commit": "e47878dcf1ccc30136b30d19ab19fe76946d61cd" }, - "nvim-dap-ui": { "branch": "master", "commit": "cf91d5e2d07c72903d052f5207511bf7ecdb7122" }, - "nvim-dap-virtual-text": { "branch": "master", "commit": "fbdb48c2ed45f4a8293d0d483f7730d24467ccb6" }, - "nvim-lspconfig": { "branch": "master", "commit": "66fd02ad1c7ea31616d3ca678fa04e6d0b360824" }, - "nvim-nio": { "branch": "master", "commit": "21f5324bfac14e22ba26553caf69ec76ae8a7662" }, - "nvim-notify": { "branch": "master", "commit": "8701bece920b38ea289b457f902e2ad184131a5d" }, - "nvim-tree.lua": { "branch": "master", "commit": "037d89e60fb01a6c11a48a19540253b8c72a3c32" }, - "nvim-treesitter": { "branch": "main", "commit": "45a07f869b0cffba342276f2c77ba7c116d35db8" }, - "nvim-ufo": { "branch": "main", "commit": "ab3eb124062422d276fae49e0dd63b3ad1062cfc" }, - "nvim-web-devicons": { "branch": "master", "commit": "746ffbb17975ebd6c40142362eee1b0249969c5c" }, - "persisted.nvim": { "branch": "main", "commit": "14cc1db0052ea26f2d2d2f1b861845dae58b7ead" }, - "plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" }, - "promise-async": { "branch": "main", "commit": "119e8961014c9bfaf1487bf3c2a393d254f337e2" }, - "snacks.nvim": { "branch": "main", "commit": "fe7cfe9800a182274d0f868a74b7263b8c0c020b" }, - "telescope.nvim": { "branch": "master", "commit": "ad7d9580338354ccc136e5b8f0aa4f880434dcdc" }, - "typst-preview.nvim": { "branch": "master", "commit": "e123a7ab64e52d836e00dea9251e85b201f38966" }, - "vim-highlightedyank": { "branch": "master", "commit": "285a61425e79742997bbde76a91be6189bc988fb" }, - "which-key.nvim": { "branch": "main", "commit": "3aab2147e74890957785941f0c1ad87d0a44c15a" } -} diff --git a/nvim/lua/configs/bufferline.lua b/nvim/lua/configs/bufferline.lua deleted file mode 100644 index f0a0c68..0000000 --- a/nvim/lua/configs/bufferline.lua +++ /dev/null @@ -1,64 +0,0 @@ -local bufferline = require('bufferline') -bufferline.setup { - options = { - mode = "buffers", -- set to "tabs" to only show tabpages instead - style_preset = bufferline.style_preset.default, - themable = true, - indicator = { - icon = '▎', - style = 'icon', - }, - buffer_close_icon = '󰅖', - modified_icon = '● ', - close_icon = ' ', - left_trunc_marker = ' ', - right_trunc_marker = ' ', - max_name_length = 18, - max_prefix_length = 15, - truncate_names = true, - tab_size = 18, - custom_filter = function(buf_number, buf_numbers) - if vim.bo[buf_number].filetype ~= "" then - return true - end - if vim.fn.bufname(buf_number) ~= "" then - return true - end - if vim.fn.getcwd() == "" and vim.bo[buf_number].filetype ~= "wiki" then - return true - end - if buf_numbers[1] ~= buf_number then - return true - end - end, - offsets = { - { - filetype = "NvimTree", - text = "File Explorer", - text_align = "left", - separator = true - } - }, - color_icons = true, - get_element_icon = function(element) - local icon, hl = require('nvim-web-devicons').get_icon_by_filetype(element.filetype, { default = false }) - return icon, hl - end, - show_buffer_icons = true, - show_buffer_close_icons = true, - show_close_icon = true, - show_tab_indicators = true, - separator_style = "slant", - enforce_regular_tabs = false, - always_show_bufferline = true, - auto_toggle_bufferline = true, - hover = { - enabled = true, - delay = 200, - reveal = {'close'} - }, - pick = { - alphabet = "abcdefghijklmopqrstuvwxyzABCDEFGHIJKLMOPQRSTUVWXYZ1234567890", - }, - } -} diff --git a/nvim/lua/configs/cmp.lua b/nvim/lua/configs/cmp.lua deleted file mode 100644 index e576e37..0000000 --- a/nvim/lua/configs/cmp.lua +++ /dev/null @@ -1,55 +0,0 @@ -local cmp = require "cmp" - -local options = { - completion = { completeopt = "menu,menuone" }, - - snippet = { - expand = function(args) - require("luasnip").lsp_expand(args.body) - end, - }, - - mapping = { - [""] = cmp.mapping.select_prev_item(), - [""] = cmp.mapping.select_next_item(), - [""] = cmp.mapping.scroll_docs(-4), - [""] = cmp.mapping.scroll_docs(4), - [""] = cmp.mapping.complete(), - [""] = cmp.mapping.close(), - - [""] = cmp.mapping.confirm { - behavior = cmp.ConfirmBehavior.Insert, - select = true, - }, - - [""] = cmp.mapping(function(fallback) - if cmp.visible() then - cmp.select_next_item() - elseif require("luasnip").expand_or_jumpable() then - require("luasnip").expand_or_jump() - else - fallback() - end - end, { "i", "s" }), - - [""] = cmp.mapping(function(fallback) - if cmp.visible() then - cmp.select_prev_item() - elseif require("luasnip").jumpable(-1) then - require("luasnip").jump(-1) - else - fallback() - end - end, { "i", "s" }), - }, - - sources = { - { name = "nvim_lsp" }, - { name = "luasnip" }, - { name = "buffer" }, - { name = "nvim_lua" }, - { name = "async_path" }, - }, -} - -return vim.tbl_deep_extend("force", options, {}) diff --git a/nvim/lua/configs/conform.lua b/nvim/lua/configs/conform.lua deleted file mode 100644 index 9cfbe75..0000000 --- a/nvim/lua/configs/conform.lua +++ /dev/null @@ -1,15 +0,0 @@ -local options = { - formatters_by_ft = { - lua = { "stylua" }, - cpp = { "clang-format" }, - go = { "gofmr" }, - }, - - format_on_save = { - -- These options will be passed to conform.format() - timeout_ms = 500, - lsp_fallback = true, - }, -} - -return options diff --git a/nvim/lua/configs/gitsigns.lua b/nvim/lua/configs/gitsigns.lua deleted file mode 100644 index d911b56..0000000 --- a/nvim/lua/configs/gitsigns.lua +++ /dev/null @@ -1,53 +0,0 @@ -return { - signs = { - add = { text = "▎" }, - change = { text = "▎" }, - delete = { text = "" }, - topdelete = { text = "" }, - changedelete = { text = "▎" }, - untracked = { text = "▎" }, - }, - signs_staged = { - add = { text = "▎" }, - change = { text = "▎" }, - delete = { text = "" }, - topdelete = { text = "" }, - changedelete = { 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, silent = true }) - end - - -- stylua: ignore start - map("n", "]h", function() - if vim.wo.diff then - vim.cmd.normal({ "]c", bang = true }) - else - gs.nav_hunk("next") - end - end, "Next Hunk") - map("n", "[h", function() - if vim.wo.diff then - vim.cmd.normal({ "[c", bang = true }) - else - gs.nav_hunk("prev") - end - end, "Prev Hunk") - map("n", "]H", function() gs.nav_hunk("last") end, "Last Hunk") - map("n", "[H", function() gs.nav_hunk("first") end, "First Hunk") - map({ "n", "x" }, "ghs", ":Gitsigns stage_hunk", "Stage Hunk") - map({ "n", "x" }, "ghr", ":Gitsigns reset_hunk", "Reset Hunk") - map("n", "ghS", gs.stage_buffer, "Stage Buffer") - map("n", "ghu", gs.undo_stage_hunk, "Undo Stage Hunk") - map("n", "ghR", gs.reset_buffer, "Reset Buffer") - map("n", "ghp", gs.preview_hunk_inline, "Preview Hunk Inline") - map("n", "ghb", function() gs.blame_line({ full = true }) end, "Blame Line") - map("n", "ghB", function() gs.blame() end, "Blame Buffer") - map("n", "ghd", gs.diffthis, "Diff This") - map("n", "ghD", function() gs.diffthis("~") end, "Diff This ~") - map({ "o", "x" }, "ih", ":Gitsigns select_hunk", "GitSigns Select Hunk") - end, -} diff --git a/nvim/lua/configs/lazy.lua b/nvim/lua/configs/lazy.lua deleted file mode 100644 index f533341..0000000 --- a/nvim/lua/configs/lazy.lua +++ /dev/null @@ -1,26 +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 = "\\" - -require("lazy").setup({ - spec = { - { import = "plugins" }, - }, - install = { colorscheme = { "habamax" } }, - checker = { enabled = true }, -}) diff --git a/nvim/lua/configs/lsp/e-lspconfig.lua b/nvim/lua/configs/lsp/e-lspconfig.lua deleted file mode 100644 index 48c2f29..0000000 --- a/nvim/lua/configs/lsp/e-lspconfig.lua +++ /dev/null @@ -1,55 +0,0 @@ -local M = {} -local map = vim.keymap.set - --- export on_attach & capabilities -M.on_attach = function(_, bufnr) - local function opts(desc) - return { buffer = bufnr, desc = "LSP " .. desc } - end - - map("n", "gD", vim.lsp.buf.declaration, opts "Go to declaration") - map("n", "gd", vim.lsp.buf.definition, opts "Go to definition") - map("n", "wa", vim.lsp.buf.add_workspace_folder, opts "Add workspace folder") - map("n", "wr", vim.lsp.buf.remove_workspace_folder, opts "Remove workspace folder") - - map("n", "wl", function() - print(vim.inspect(vim.lsp.buf.list_workspace_folders())) - end, opts "List workspace folders") - - map("n", "D", vim.lsp.buf.type_definition, opts "Go to type definition") -end - --- disable semanticTokens -M.on_init = function(client, _) - if vim.fn.has "nvim-0.11" ~= 1 then - if client.supports_method "textDocument/semanticTokens" then - client.server_capabilities.semanticTokensProvider = nil - end - else - if client:supports_method "textDocument/semanticTokens" then - client.server_capabilities.semanticTokensProvider = nil - end - end -end - -M.capabilities = vim.lsp.protocol.make_client_capabilities() - -M.capabilities.textDocument.completion.completionItem = { - documentationFormat = { "markdown", "plaintext" }, - snippetSupport = true, - preselectSupport = true, - insertReplaceSupport = true, - labelDetailsSupport = true, - deprecatedSupport = true, - commitCharactersSupport = true, - tagSupport = { valueSet = { 1 } }, - resolveSupport = { - properties = { - "documentation", - "detail", - "additionalTextEdits", - }, - }, -} - -return M diff --git a/nvim/lua/configs/lsp/lspconfig.lua b/nvim/lua/configs/lsp/lspconfig.lua deleted file mode 100644 index 41754d4..0000000 --- a/nvim/lua/configs/lsp/lspconfig.lua +++ /dev/null @@ -1,107 +0,0 @@ -local on_attach = require("configs.lsp.e-lspconfig").on_attach -local on_init = require("configs.lsp.e-lspconfig").on_init -local capabilities = require("configs.lsp.e-lspconfig").capabilities - --- C/C++ -vim.lsp.config('clangd', { - on_attach = on_attach, - on_init = on_init, - capabilities = capabilities, - cmd = { - "clangd", - "--background-index", - "--background-index-priority=normal", - "--clang-tidy", - "--experimental-modules-support", - "--all-scopes-completion", - "--completion-style=detailed", - "--header-insertion=iwyu", - "--limit-references=5", - "--pch-storage=disk", - }, - filetypes = { "c", "cpp", "h", "hpp", "objc", "objcpp" }, - root_markers = { '.git' }, -}) -vim.lsp.enable('clangd') - --- Go (gopls) lsp server -vim.lsp.config('gopls', { - on_attach = on_attach, - on_init = on_init, - capabilities = capabilities, - cmd = { 'gopls' }, - filetypes = { 'go', 'gomod', 'gowork', 'gotmpl' }, - root_markers = { 'go.mod', '.git' }, - single_file_support = true, - settings = { - gopls = { - completeUnimported = true, - usePlaceholders = true, - analyses = { - unusedparams = true, - }, - staticcheck = true, - gofumpt = true, - }, - }, -}) -vim.lsp.enable('gopls') - --- PhP -vim.lsp.config('phpactor', { - cmd = { 'phpactor', 'language-server' }, - filetypes = { 'php' }, - root_markers = { 'composer.json', '.git' }, - init_options = { - ["language_server_phpstan.enabled"] = false, - ["language_server_psalm.enabled"] = false, - } -}) -vim.lsp.enable('phpactor') - --- Lua -vim.lsp.config('lua_ls', { - cmd = { 'lua-language-server' }, - filetypes = { 'lua' }, - root_markers = { '.luarc.json', '.luarc.jsonc', '.git' }, - single_file_support = true, - settings = { - Lua = { - telemetry = { enable = false }, - runtime = { version = 'LuaJIT' }, - diagnostics = { globals = { 'vim' } }, - workspace = { - checkThirdParty = false, - library = { - vim.env.VIMRUNTIME, - vim.fn.stdpath('config'), - }, - }, - }, - } -}) -vim.lsp.enable('lua_ls') - --- Bash -vim.lsp.config('bashls', { - cmd = { 'bash-language-server', 'start' }, - filetypes = { 'sh', 'bash' }, - root_markers = { '.git' }, - single_file_support = true, -}) -vim.lsp.enable('bashls') - --- Meson -vim.lsp.config('meson_ls', { - cmd = { 'mesonlsp' }, - filetypes = { 'meson' }, - root_markers = { 'meson.build', '.git' }, - single_file_support = true, - settings = {} -}) -vim.lsp.enable('meson_ls') - --- For all -vim.diagnostic.config({ - virtual_text = false, -}) diff --git a/nvim/lua/configs/lualine.lua b/nvim/lua/configs/lualine.lua deleted file mode 100644 index e83b767..0000000 --- a/nvim/lua/configs/lualine.lua +++ /dev/null @@ -1,54 +0,0 @@ -require('lualine').setup { - options = { - icons_enabled = true, - theme = 'auto', - component_separators = { left = '', right = ''}, - section_separators = { left = '', right = ''}, - disabled_filetypes = { - statusline = {}, - winbar = {}, - }, - ignore_focus = {}, - always_divide_middle = true, - always_show_tabline = true, - globalstatus = false, - refresh = { - statusline = 1000, - tabline = 1000, - winbar = 1000, - refresh_time = 16, -- ~60fps - events = { - 'WinEnter', - 'BufEnter', - 'BufWritePost', - 'SessionLoadPost', - 'FileChangedShellPost', - 'VimResized', - 'Filetype', - 'CursorMoved', - 'CursorMovedI', - 'ModeChanged', - }, - } - }, - sections = { - lualine_a = {'mode'}, - lualine_b = {'branch', 'diff', 'diagnostics'}, - lualine_c = {'filename'}, - lualine_x = {'fileformat', 'filetype'}, - lualine_y = {'lsp_status'}, - lualine_z = {'location'} - }, - inactive_sections = { - lualine_a = {}, - lualine_b = {}, - lualine_c = {'filename'}, - lualine_x = {'location'}, - lualine_y = {}, - lualine_z = {} - }, - tabline = {}, - winbar = {}, - inactive_winbar = {}, - extensions = {} -} diff --git a/nvim/lua/configs/luasnip.lua b/nvim/lua/configs/luasnip.lua deleted file mode 100644 index ef53ac6..0000000 --- a/nvim/lua/configs/luasnip.lua +++ /dev/null @@ -1,11 +0,0 @@ --- vscode format -require("luasnip.loaders.from_vscode").lazy_load { exclude = vim.g.vscode_snippets_exclude or {} } -require("luasnip.loaders.from_vscode").lazy_load { paths = vim.g.vscode_snippets_path or "" } - --- snipmate format -require("luasnip.loaders.from_snipmate").load() -require("luasnip.loaders.from_snipmate").lazy_load { paths = vim.g.snipmate_snippets_path or "" } - --- lua format -require("luasnip.loaders.from_lua").load() -require("luasnip.loaders.from_lua").lazy_load { paths = vim.g.lua_snippets_path or "" } diff --git a/nvim/lua/configs/nvim-dap.lua b/nvim/lua/configs/nvim-dap.lua deleted file mode 100644 index 7f48a79..0000000 --- a/nvim/lua/configs/nvim-dap.lua +++ /dev/null @@ -1,84 +0,0 @@ -local M = {} - -function M.setup() - local dap = require("dap") - local dapui = require("dapui") - - -- Настройка адаптера codelldb для C/C++ - dap.adapters.codelldb = { - type = 'server', - port = '${port}', - executable = { - command = vim.fn.stdpath("data") .. '/mason/bin/codelldb', - args = { '--port', '${port}' }, - } - } - - -- Конфигурации для C/C++ - dap.configurations.cpp = { - { - name = "Launch file", - type = "codelldb", - request = "launch", - program = function() - return vim.fn.input('Path to executable: ', vim.fn.getcwd() .. '/', 'file') - end, - cwd = '${workspaceFolder}', - stopOnEntry = false, - args = {}, - }, - } - - -- Используем те же конфигурации для C - dap.configurations.c = dap.configurations.cpp - - -- Настройка dap-ui :cite[1]:cite[4] - dapui.setup({ - layouts = { - { - elements = { - { id = "scopes", size = 0.33 }, - { id = "breakpoints", size = 0.17 }, - { id = "stacks", size = 0.25 }, - { id = "watches", size = 0.25 }, - }, - size = 0.33, - position = "right", - }, - { - elements = { - { id = "repl", size = 0.45 }, - { id = "console", size = 0.55 }, - }, - size = 0.27, - position = "bottom", - }, - }, - }) - - -- Автоматическое открытие/закрытие UI :cite[1]:cite[9] - dap.listeners.after.event_initialized["dapui_config"] = function() - dapui.open({}) - end - - dap.listeners.before.event_terminated["dapui_config"] = function() - dapui.close({}) - end - - dap.listeners.before.event_exited["dapui_config"] = function() - dapui.close({}) - end - - -- Цвета на задний фон для debug - vim.api.nvim_set_hl(0, 'DapBreakpoint', { fg = '#993939', bg = '#31353f' }) - vim.api.nvim_set_hl(0, 'DapLogPoint', { fg = '#61afef', bg = '#31353f' }) - vim.api.nvim_set_hl(0, 'DapStopped', { fg = '#98c379', bg = '#31353f' }) - -- Настройка значков для точек останова :cite[1]:cite[10] - vim.fn.sign_define('DapBreakpoint', { text='', texthl='DapBreakpoint', linehl='DapBreakpoint', numhl='DapBreakpoint' }) - vim.fn.sign_define('DapBreakpointCondition', { text='ﳁ', texthl='DapBreakpoint', linehl='DapBreakpoint', numhl='DapBreakpoint' }) - vim.fn.sign_define('DapBreakpointRejected', { text='', texthl='DapBreakpoint', linehl='DapBreakpoint', numhl= 'DapBreakpoint' }) - vim.fn.sign_define('DapLogPoint', { text='', texthl='DapLogPoint', linehl='DapLogPoint', numhl= 'DapLogPoint' }) - vim.fn.sign_define('DapStopped', { text='', texthl='DapStopped', linehl='DapStopped', numhl= 'DapStopped' })vim.fn.sign_define("DapBreakpointRejected", { text = "❌", texthl = "LspDiagnosticsSignHint" }) -end - -return M diff --git a/nvim/lua/configs/nvimtree.lua b/nvim/lua/configs/nvimtree.lua deleted file mode 100644 index 45d2a79..0000000 --- a/nvim/lua/configs/nvimtree.lua +++ /dev/null @@ -1,32 +0,0 @@ -return { - filters = { dotfiles = false, git_ignored = false, }, - disable_netrw = true, - hijack_cursor = true, - sync_root_with_cwd = true, - update_focused_file = { - enable = true, - update_root = false, - }, - view = { - width = 30, - preserve_window_proportions = true, - }, - renderer = { - root_folder_label = false, - highlight_git = true, - indent_markers = { enable = true }, - icons = { - glyphs = { - default = "󰈚", - folder = { - default = "", - empty = "", - empty_open = "", - open = "", - symlink = "", - }, - git = { unmerged = "" }, - }, - }, - }, -} diff --git a/nvim/lua/configs/snacks.lua b/nvim/lua/configs/snacks.lua deleted file mode 100644 index e69de29..0000000 diff --git a/nvim/lua/configs/telescope.lua b/nvim/lua/configs/telescope.lua deleted file mode 100644 index ee5a959..0000000 --- a/nvim/lua/configs/telescope.lua +++ /dev/null @@ -1,22 +0,0 @@ -require("telescope").setup(){ - defaults = { - prompt_prefix = "  ", - selection_caret = " ", - entry_prefix = " ", - sorting_strategy = "ascending", - layout_config = { - horizontal = { - prompt_position = "top", - preview_width = 0.55, - }, - width = 0.87, - height = 0.80, - }, - mappings = { - n = { ["q"] = require("telescope.actions").close }, - }, - }, - - extensions_list = { "themes", "terms", "noice", "persisted" }, - extensions = { "noice", "persisted" }, -} diff --git a/nvim/lua/configs/treesitter.lua b/nvim/lua/configs/treesitter.lua deleted file mode 100644 index d4f788a..0000000 --- a/nvim/lua/configs/treesitter.lua +++ /dev/null @@ -1,46 +0,0 @@ -return { - ensure_installed = { - "c", - "cpp", - "make", - "cmake", - "diff", - "doxygen", - "git_config", - "gitcommit", - "gitignore", - "html", - "javadoc", - "javascript", - "jsdoc", - "json", - "jsonc", - "lua", - "luadoc", - "luap", - "markdown", - "markdown_inline", - "meson", - "php", - "phpdoc", - "printf", - "python", - "query", - "regex", - "sql", - "toml", - "tsx", - "typescript", - "vim", - "vimdoc", - "xml", - "yaml" - }, - - highlight = { - enable = true, - use_languagetree = true, - }, - - indent = { enable = true }, -} diff --git a/nvim/lua/configs/ufo.lua b/nvim/lua/configs/ufo.lua deleted file mode 100644 index 2f54ac3..0000000 --- a/nvim/lua/configs/ufo.lua +++ /dev/null @@ -1,21 +0,0 @@ -vim.o.foldcolumn = '1' -- '0' is not bad -vim.o.foldlevel = 99 -- Using ufo provider need a large value, feel free to decrease the value -vim.o.foldlevelstart = 99 -vim.o.foldenable = true - --- Using ufo provider need remap `zR` and `zM`. If Neovim is 0.6.1, remap yourself -vim.keymap.set('n', 'zR', require('ufo').openAllFolds) -vim.keymap.set('n', 'zM', require('ufo').closeAllFolds) -vim.keymap.set('n', 'zK', function() - local winid = require('ufo').peekFoldedLinesUnderCursor() - if not winid then - vim.lsp.buf.hover() - end -end, {desc = "Peek Fold"}) - -require("ufo").setup({ - provider_selector = function(bufnr, filetype, buftype) - return { 'lsp', 'indent' } - end -}) - diff --git a/nvim/lua/custom/darcula.lua b/nvim/lua/custom/darcula.lua deleted file mode 100644 index 2f337f4..0000000 --- a/nvim/lua/custom/darcula.lua +++ /dev/null @@ -1,804 +0,0 @@ ----@class Config -local config = { - opt = { - integrations = { - telescope = false, - lualine = true, - lsp_semantics_token = true, - nvim_cmp = true, - dap_nvim = true, - }, - }, -} - ----@class MyModule -local M = {} - ----@type Config -M.config = config - -local color = { - green = "#98be65", - red = "#f43753", - grey = "#C9D0D3", - light_blue = "#b3deef", - background = "#383838", - pale_gold = "#d3b987", - dark = "#2B2B2B", - bright_sky = "#73cef4", - golden_yellow = "#ffc24b", - light_olive_green = "#c9d05c", - medium_gray = "#4c4c4c", - light_brown = "#dc9656", - silver_gray = "#b8b8b8", - bright_cyan = "#00f1f5", - light_slate_gray = "#abb2bf", - dark_grey = "#484848", - comment = "#808080", - light_lime_green = "#a9ff68", - peach_orange = "#ff9e64", - slate_gray = "#6d8086", - light_lavender = "#cba6f7", - very_light_gray = "#eeeeee", - dark_charcoal_gray = "#404040", - very_dark_gray = "#242424", - bright_pink = "#f70067", - burnt_orange = "#CC7832", - dark_maroon = "#7a1b29", - steel_blue = "#596f77", - bright_yellow_green = "#e3e346", - copper_brown = "#C07C41", - deep_fuchsia = "#b33076", - lavender = "#9876AA", - deep_light_blue = "#51afef", - pale_taupe = "#AD9E7D", - olive_green = "#6A8759", - _52 = "#c95942", - _54 = "#bf4537", - _64 = "#89d957", - _70 = "#4dd158", - _66 = "#6FAFBD", - _71 = "#4B4E4F", - _74 = "#3C3F40", - _38 = "#881515", - _39 = "#73797e", - _47 = "#f7bb3b", - _50 = "#d1d4cf", - _53 = "#c955ae", - _55 = "#b8733e", - _56 = "#afd700", - _57 = "#ad475f", - _58 = "#FFC66D", - _61 = "#AFBF7E", - _68 = "#6897BB", - _72 = "#4682b4", - _75 = "#392a52", - _82 = "#151838", -} - ----@param args Config? --- you can define your setup function here. Usually configurations can be merged, accepting outside params and --- you can also put some validation here for those. -M.setup = function(args) - M.config = vim.tbl_deep_extend("force", M.config, args or {}) - if vim.g.colors_name ~= nil then - vim.cmd("highlight clear") - end - - if args and type(args.override) == "function" then - c = args.override(color) - color = vim.tbl_deep_extend("force", color, c) - end - - -- neovim version should be higher than 0.8.3 - if vim.fn.has("nvim-0.8.3") == 0 then - vim.cmd( - "echohl WarningMsg | echo 'Your neovim version is lower than 0.8.3, some features may not work correctly!' | echohl None" - ) - end - - vim.g.colors_name = "darcula-dark" - vim.o.termguicolors = true - M.configure_highlights() -end - -M.configure_highlights = function() - -- colors - -- Highlight groups - local hi = vim.api.nvim_set_hl - - if M.config.opt.integrations.lsp_semantics_token then - -- lsp semantics token - hi(0, "@attribute", { link = "TSAttribute" }) - hi(0, "@boolean", { link = "TSBoolean" }) - hi(0, "@character", { link = "TSCharacter" }) - hi(0, "@character.special", { link = "SpecialChar" }) - hi(0, "@class", { link = "TSType" }) - hi(0, "@comment", { link = "TSComment" }) - hi(0, "@conditional", { link = "TSConditional" }) - hi(0, "@constant", { link = "TSConstant" }) - hi(0, "@constant.builtin", { link = "TSConstantBuiltin" }) - hi(0, "@constant.macro", { link = "TSConstant" }) - hi(0, "@constructor", { link = "TSConstructor" }) - hi(0, "@decorator", { link = "Identifier" }) - hi(0, "@enum", { link = "TSType" }) - hi(0, "@enumMember", { link = "Constant" }) - hi(0, "@error", { link = "TSError" }) - hi(0, "@event", { link = "Identifier" }) - hi(0, "@exception", { link = "TSException" }) - hi(0, "@field", { link = "TSField" }) - hi(0, "@float", { link = "TSFloat" }) - hi(0, "@function", { link = "TSFunction" }) - hi(0, "@function.builtin", { link = "TSFuncBuiltin" }) - hi(0, "@function.call", { link = "TSFunctionCall" }) - hi(0, "@function.macro", { link = "TSFuncMacro" }) - hi(0, "@include", { link = "TSInclude" }) - hi(0, "@interface", { link = "Structure" }) - hi(0, "@keyword", { link = "TSKeyword" }) - hi(0, "@keyword.function", { link = "TSKeywordFunction" }) - hi(0, "@keyword.operator", { link = "TSKeywordOperator" }) - hi(0, "@keyword.return", { link = "TSKeyword" }) - hi(0, "@label", { link = "TSLabel" }) - hi(0, "@method", { link = "TSMethod" }) - hi(0, "@method.call", { link = "TSMethodCall" }) - hi(0, "@modifier", { link = "Identifier" }) - hi(0, "@namespace", { link = "TSNamespace" }) - hi(0, "@none", { link = "TSNone" }) - hi(0, "@number", { link = "TSNumber" }) - hi(0, "@operator", { link = "TSOperator" }) - hi(0, "@parameter", { link = "TSParameter" }) - hi(0, "@property", { link = "TSVariable" }) - hi(0, "@punctuation.bracket", { link = "TSPunctBracket" }) - hi(0, "@punctuation.delimiter", { link = "TSPunctDelimiter" }) - hi(0, "@punctuation.special", { link = "TSPunctSpecial" }) - hi(0, "@regexp", { link = "TSStringRegex" }) - hi(0, "@repeat", { link = "TSRepeat" }) - hi(0, "@string", { link = "TSString" }) - hi(0, "@string.escape", { link = "TSStringEscape" }) - hi(0, "@string.regex", { link = "TSStringRegex" }) - hi(0, "@string.special", { link = "SpecialChar" }) - hi(0, "@struct", { link = "TSType" }) - hi(0, "@symbol", { link = "TSSymbol" }) - hi(0, "@tag", { link = "TSTag" }) - hi(0, "@tag.attribute", { link = "TSAttribute" }) - hi(0, "@tag.delimiter", { link = "TSTagDelimiter" }) - hi(0, "@text", { link = "TSText" }) - hi(0, "@text.danger", { link = "DiagnosticError" }) - hi(0, "@text.emphasis", { link = "TSEmphasis" }) - hi(0, "@text.environment", { link = "Macro" }) - hi(0, "@text.environment.name", { link = "Type" }) - hi(0, "@text.literal", { link = "TSLiteral" }) - hi(0, "@text.math", { link = "Number" }) - hi(0, "@text.note", { link = "Tag" }) - hi(0, "@text.reference", { link = "TSParameterReference" }) - hi(0, "@text.strike", { link = "TSStrike" }) - hi(0, "@text.strong", { link = "TSStrong" }) - hi(0, "@text.title", { link = "TSTitle" }) - hi(0, "@text.todo", { link = "Todo" }) - hi(0, "@text.underline", { link = "TSUnderline" }) - hi(0, "@text.uri", { link = "TSURI" }) - hi(0, "@text.warning", { link = "DiagnosticWarn" }) - hi(0, "@type", { link = "TSType" }) - hi(0, "@type.builtin", { link = "TSTypeBuiltin" }) - hi(0, "@type.definition", { link = "TSTypeDefinition" }) - hi(0, "@type.qualifier", { link = "TSType" }) - hi(0, "@typeParameter", { link = "Type" }) - hi(0, "@variable", { link = "TSVariable" }) - hi(0, "@variable.builtin", { link = "TSVariableBuiltin" }) - hi(0, "@lsp.type.namespace", { link = "TSNamespace" }) - hi(0, "@lsp.type.variable", { link = "TSVariable" }) - hi(0, "@lsp.type.parameter", { link = "TSVariable" }) - hi(0, "@lsp.typemod.variable.readonly", { link = "TSConstant" }) - hi(0, "@lsp.type.type", { link = "TSType" }) - hi(0, "@lsp.type.function", {}) - hi(0, "@lsp.type.method", {}) - hi(0, "@lsp.type.comment", {}) - hi(0, "@lsp.typemod.variable.defaultLibrary", { link = "TSKeyword" }) - hi(0, "@lsp.mod.defaultLibrary.go", { link = "TSKeyword" }) - hi(0, "@lsp.type.property", { link = "TSField" }) - hi(0, "@tag.attribute.tsx", { link = "TSParameter" }) - hi(0, "@tag.attribute.javascript", { link = "TSParameter" }) - end - - hi(0, "Bold", { bold = true }) - hi(0, "Boolean", { fg = color.light_brown }) - hi(0, "Character", { fg = color.red }) - - -- nvim-cmp - if M.config.opt.integrations.nvim_cmp then - hi(0, "Pmenu", { bg = color._74, ctermbg = 13, ctermfg = 0 }) - hi(0, "PmenuSel", { bg = color._71, ctermbg = 0, ctermfg = 242 }) - hi(0, "CmpDocumentation", { fg = color.grey }) - hi(0, "CmpDocumentationBorder", { fg = color.grey }) - hi(0, "CmpItemAbbr", { fg = color.grey }) - hi(0, "CmpItemAbbrDefault", { fg = color.grey }) - hi(0, "CmpItemAbbrDeprecated", { fg = color.medium_gray, strikethrough = true }) - hi(0, "CmpItemAbbrDeprecatedDefault", { fg = color.medium_gray }) - hi(0, "CmpItemAbbrMatch", { fg = color.light_blue }) - hi(0, "CmpItemAbbrMatchDefault", { fg = color.grey }) - hi(0, "CmpItemAbbrMatchFuzzy", { fg = color.light_blue }) - hi(0, "CmpItemAbbrMatchFuzzyDefault", { fg = color.grey }) - hi(0, "CmpItemKindClass", { fg = color.golden_yellow }) - hi(0, "CmpItemKindClassDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindColorDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindConstant", { fg = color.light_brown }) - hi(0, "CmpItemKindConstantDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindConstructor", { fg = color.light_blue }) - hi(0, "CmpItemKindConstructorDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindDefault", { fg = color.bright_sky }) - hi(0, "CmpItemKindEnum", { fg = color.golden_yellow }) - hi(0, "CmpItemKindEnumDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindEnumMember", { fg = color.golden_yellow }) - hi(0, "CmpItemKindEnumMemberDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindEvent", { fg = color.golden_yellow }) - hi(0, "CmpItemKindEventDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindField", { fg = color.red }) - hi(0, "CmpItemKindFieldDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindFileDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindFolderDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindFunction", { fg = color.light_blue }) - hi(0, "CmpItemKindFunctionDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindInterface", { fg = color.golden_yellow }) - hi(0, "CmpItemKindInterfaceDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindKeyword", { fg = color.pale_gold }) - hi(0, "CmpItemKindKeywordDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindMethod", { fg = color.light_blue }) - hi(0, "CmpItemKindMethodDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindModule", { fg = color.grey }) - hi(0, "CmpItemKindModuleDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindOperator", { fg = color.grey }) - hi(0, "CmpItemKindOperatorDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindProperty", { fg = color.red }) - hi(0, "CmpItemKindPropertyDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindReference", { fg = color.red }) - hi(0, "CmpItemKindReferenceDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindSnippet", { fg = color.silver_gray }) - hi(0, "CmpItemKindSnippetDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindStruct", { fg = color.golden_yellow }) - hi(0, "CmpItemKindStructDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindTextDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindTypeParameter", { fg = color.golden_yellow }) - hi(0, "CmpItemKindTypeParameterDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindUnit", { fg = color.golden_yellow }) - hi(0, "CmpItemKindUnitDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindValue", { fg = color.light_brown }) - hi(0, "CmpItemKindValueDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemKindVariable", { fg = color.red }) - hi(0, "CmpItemKindVariableDefault", { link = "CmpItemKind" }) - hi(0, "CmpItemMenu", { fg = color.silver_gray }) - hi(0, "CmpItemMenuDefault", { fg = color.grey }) - hi(0, "ColorColumn", { bg = color.background, ctermbg = 1 }) - hi(0, "Comment", { ctermfg = 14 }) - hi(0, "Conceal", { ctermbg = 242, ctermfg = 7, fg = color.light_blue }) - hi(0, "Conditional", { fg = color.pale_gold }) - end - -- conflict-marker.vim - - hi(0, "Constant", { ctermfg = 13, fg = color.light_brown }) - - -- copilot.vim - hi(0, "CopilotSuggestion", { ctermfg = 244, fg = color.comment }) - - -- cursor - hi(0, "Cursor", { bg = color.very_light_gray, fg = color.dark }) - hi(0, "CursorColumn", { bg = color.background, ctermbg = 242 }) - hi(0, "CursorLine", { bg = color.background }) - hi(0, "CursorLineNr", { bg = color.background, bold = true, ctermfg = 11, fg = color.silver_gray }) - - -- dap.nvim - if M.config.opt.integrations.dap_nvim then - hi(0, "DapUIBreakpointsCurrentLine", { bold = true, fg = color.light_lime_green }) - hi(0, "DapUIBreakpointsDisabledLine", { fg = color.dark_grey }) - hi(0, "DapUIBreakpointsInfo", { fg = color.light_lime_green }) - hi(0, "DapUIBreakpointsPath", { fg = color.bright_cyan }) - hi(0, "DapUIDecoration", { fg = color.bright_cyan }) - hi(0, "DapUIFloatBorder", { fg = color.bright_cyan }) - hi(0, "DapUILineNumber", { fg = color.bright_cyan }) - hi(0, "DapUIModifiedValue", { bold = true, fg = color.bright_cyan }) - hi(0, "DapUIPlayPause", { fg = color.light_lime_green }) - hi(0, "DapUIPlayPauseNC", { fg = color.light_lime_green }) - hi(0, "DapUIRestart", { fg = color.light_lime_green }) - hi(0, "DapUIRestartNC", { fg = color.light_lime_green }) - hi(0, "DapUIScope", { fg = color.bright_cyan }) - hi(0, "DapUISource", { fg = color.light_lavender }) - hi(0, "DapUIStepBack", { fg = color.bright_cyan }) - hi(0, "DapUIStepBackNC", { fg = color.bright_cyan }) - hi(0, "DapUIStepInto", { fg = color.bright_cyan }) - hi(0, "DapUIStepIntoNC", { fg = color.bright_cyan }) - hi(0, "DapUIStepOut", { fg = color.bright_cyan }) - hi(0, "DapUIStepOutNC", { fg = color.bright_cyan }) - hi(0, "DapUIStepOver", { fg = color.bright_cyan }) - hi(0, "DapUIStepOverNC", { fg = color.bright_cyan }) - hi(0, "DapUIStop", { fg = color.bright_pink }) - hi(0, "DapUIStopNC", { fg = color.bright_pink }) - hi(0, "DapUIStoppedThread", { fg = color.bright_cyan }) - hi(0, "DapUIThread", { fg = color.light_lime_green }) - hi(0, "DapUIType", { fg = color.light_lavender }) - hi(0, "DapUIUnavailable", { fg = color.dark_grey }) - hi(0, "DapUIUnavailableNC", { fg = color.dark_grey }) - hi(0, "DapUIWatchesEmpty", { fg = color.bright_pink }) - hi(0, "DapUIWatchesError", { fg = color.bright_pink }) - hi(0, "DapUIWatchesValue", { fg = color.light_lime_green }) - end - hi(0, "Debug", { fg = color.red }) - hi(0, "Define", { fg = color.pale_gold }) - hi(0, "DefinitionArrow", { fg = color._57 }) - hi(0, "DefinitionBorder", { fg = color.light_blue }) - hi(0, "DefinitionFile", { bg = color._82 }) - hi(0, "Definitions", { bold = true, fg = color.light_lavender }) - hi(0, "DefinitionsIcon", { fg = color.bright_yellow_green }) - hi(0, "Delimiter", { fg = color.light_brown }) - hi(0, "DiagnosticError", { ctermfg = 1, fg = color.red }) - hi(0, "DiagnosticHint", { ctermfg = 7, fg = color.bright_sky }) - hi(0, "DiagnosticInfo", { ctermfg = 4, fg = color.grey }) - hi(0, "DiagnosticLineCol", { fg = color._39 }) - hi(0, "DiagnosticMap", { fg = color.light_lavender }) - hi(0, "DiagnosticQuickFix", { bold = true, fg = color._70 }) - hi(0, "DiagnosticUnderlineError", { sp = color.red, undercurl = true }) - hi(0, "DiagnosticUnderlineHint", { sp = color.bright_sky, undercurl = true }) - hi(0, "DiagnosticUnderlineInformation", { sp = color.light_brown, undercurl = true }) - hi(0, "DiagnosticUnderlineWarn", { sp = color.pale_gold, undercurl = true }) - hi(0, "DiagnosticUnderlineWarning", { sp = color.pale_gold, undercurl = true }) - hi(0, "DiagnosticWarn", { ctermfg = 3, fg = color.pale_gold }) - -- hi(0, "DiffAdd", { ctermbg = 4, fg = color._05 }) - -- hi(0, "DiffAdded", { fg = color._05 }) - -- hi(0, "DiffChange", { ctermbg = 5, fg = color._07 }) - -- hi(0, "DiffDelete", { bold = true, ctermbg = 6, ctermfg = 12, fg = color.red }) - -- hi(0, "DiffFile", { fg = color.red }) - -- hi(0, "DiffLine", { fg = color.light_blue }) - -- hi(0, "DiffNewFile", { fg = color._05 }) - -- hi(0, "DiffRemoved", { fg = color.red }) - -- hi(0, "DiffText", { bold = true, ctermbg = 9, fg = color.light_blue }) - hi(0, "Directory", { ctermfg = 159, fg = color.light_blue }) - hi(0, "Error", { bg = color.red, ctermbg = 9, ctermfg = 15, fg = color.dark }) - hi(0, "ErrorMsg", { ctermbg = 1, ctermfg = 15, fg = color.red }) - hi(0, "Exception", { fg = color.red }) - hi(0, "EyelinerDimmed", { fg = color.medium_gray }) - hi(0, "EyelinerPrimary", { fg = color.light_brown }) - hi(0, "EyelinerSecondary", { fg = color.pale_gold }) - hi(0, "FinderParam", { bg = color._75, bold = true, fg = color.light_lavender }) - hi(0, "FinderSpinner", { bold = true, fg = color.deep_fuchsia }) - hi(0, "FinderSpinnerBorder", { fg = color.deep_light_blue }) - hi(0, "FinderSpinnerTitle", { bold = true, fg = color.deep_fuchsia }) - hi(0, "FinderVirtText", { fg = color._52 }) - hi(0, "Float", { fg = color.light_brown }) - hi(0, "FloatBorder", { fg = color.grey }) - hi(0, "FocusedSymbol", { bg = color.background, fg = color.light_olive_green }) - hi(0, "FoldColumn", { ctermbg = 242 }) - hi(0, "Folded", { bg = color.background, ctermbg = 242 }) - hi(0, "Function", { fg = color.light_blue }) - hi(0, "GitGutterAdd", { bg = color.dark, fg = color.light_olive_green }) - hi(0, "GitGutterChange", { bg = color.dark, fg = color.light_blue }) - hi(0, "GitGutterChangeDelete", { bg = color.dark, fg = color.pale_gold }) - hi(0, "GitGutterDelete", { bg = color.dark, fg = color.red }) - hi(0, "GitSignsStagedAdd", { bg = color.dark, fg = color.green }) - hi(0, "GitSignsStagedAddLn", { bg = color.dark, fg = color.green }) - hi(0, "GitSignsStagedAddNr", { bg = color.dark, fg = color.green }) - hi(0, "GitSignsStagedChange", { bg = color.dark, fg = color.steel_blue }) - hi(0, "GitSignsStagedChangeLn", { bg = color.dark, fg = color.very_dark_gray }) - hi(0, "GitSignsStagedChangeNr", { bg = color.dark, fg = color.steel_blue }) - hi(0, "GitSignsStagedChangedelete", { bg = color.dark, fg = color.steel_blue }) - hi(0, "GitSignsStagedChangedeleteLn", { bg = color.dark, fg = color.very_dark_gray }) - hi(0, "GitSignsStagedChangedeleteNr", { bg = color.dark, fg = color.steel_blue }) - hi(0, "GitSignsStagedDelete", { bg = color.dark, fg = color.dark_maroon }) - hi(0, "GitSignsStagedDeleteNr", { bg = color.dark, fg = color.dark_maroon }) - hi(0, "GitSignsStagedTopdelete", { bg = color.dark, fg = color.dark_maroon }) - hi(0, "GitSignsStagedTopdeleteNr", { bg = color.dark, fg = color.dark_maroon }) - hi(0, "HopNextKey", { bold = true, ctermfg = 198, fg = color.bright_pink }) - hi(0, "HopNextKey1", { bold = true, ctermfg = 45, fg = color.bright_cyan }) - hi(0, "HopNextKey2", { ctermfg = 33, fg = color.bright_cyan }) - hi(0, "HopPreview", { link = "IncSearch" }) - hi(0, "HopUnmatched", { ctermfg = 242, fg = color.slate_gray, sp = color.slate_gray }) - hi(0, "Identifier", { ctermfg = 14, fg = color.red }) - hi(0, "Ignore", { ctermfg = 0, fg = color.dark }) - -- hi(0, "IlluminatedWordRead", { sp = color._09, underline = true }) - -- hi(0, "IlluminatedWordText", { sp = color._09, underline = true }) - -- hi(0, "IlluminatedWordWrite", { sp = color._09, underline = true }) - hi(0, "Implements", { bold = true, fg = color.light_lavender }) - hi(0, "ImplementsIcon", { fg = color.bright_yellow_green }) - hi(0, "IncSearch", { bg = color.light_brown, fg = color.background }) - hi(0, "Include", { fg = color.copper_brown }) - hi(0, "IndentBlanklineChar", { fg = color.dark_grey, nocombine = true }) - hi(0, "IndentBlanklineContextChar", { fg = color.silver_gray, nocombine = true }) - hi(0, "IndentBlanklineContextStart", { sp = color.golden_yellow, underline = true }) - hi(0, "IndentBlanklineSpaceChar", { ctermfg = 12, fg = color.medium_gray, nocombine = true }) - hi(0, "IndentBlanklineSpaceCharBlankline", { ctermfg = 12, fg = color.medium_gray, nocombine = true }) - hi(0, "Keyword", { fg = color.pale_gold }) - hi(0, "LSOutlinePreviewBorder", { fg = color.green }) - hi(0, "Label", { fg = color.golden_yellow }) - hi(0, "LineNr", { ctermfg = 11, fg = color.silver_gray }) - hi(0, "LspDiagnosticsDefaultError", { link = "DiagnosticError" }) - hi(0, "LspDiagnosticsDefaultHint", { link = "DiagnosticHint" }) - hi(0, "LspDiagnosticsDefaultInformation", { link = "DiagnosticInfo" }) - hi(0, "LspDiagnosticsDefaultWarning", { link = "DiagnosticWarn" }) - hi(0, "LspDiagnosticsUnderlineError", { link = "DiagnosticUnderlineError" }) - hi(0, "LspDiagnosticsUnderlineHint", { link = "DiagnosticUnderlineHint" }) - hi(0, "LspDiagnosticsUnderlineInformation", { link = "DiagnosticUnderlineInformation" }) - hi(0, "LspDiagnosticsUnderlineWarning", { link = "DiagnosticUnderlineWarning" }) - hi(0, "LspReferenceRead", { sp = color.silver_gray, underline = true }) - hi(0, "LspReferenceText", { sp = color.silver_gray, underline = true }) - hi(0, "LspReferenceWrite", { sp = color.silver_gray, underline = true }) - hi(0, "LspSagaAutoPreview", { fg = color.deep_light_blue }) - hi(0, "LspSagaCodeActionBorder", { fg = color.light_lavender }) - hi(0, "LspSagaCodeActionContent", { bold = true, fg = color.green }) - hi(0, "LspSagaCodeActionTitle", { bold = true, fg = color.burnt_orange }) - hi(0, "LspSagaDiagnosticBorder", { fg = color.light_lavender }) - hi(0, "LspSagaDiagnosticHeader", { fg = color._56 }) - hi(0, "LspSagaFinderSelection", { bold = true, fg = color._64 }) - hi(0, "LspSagaHoverBorder", { fg = color._47 }) - hi(0, "LspSagaLspFinderBorder", { fg = color.deep_light_blue }) - hi(0, "LspSagaRenameBorder", { fg = color.bright_cyan }) - hi(0, "LspSagaSignatureHelpBorder", { fg = color.green }) - hi(0, "Macro", { fg = color.red }) - hi(0, "MatchParen", { fg = color.bright_cyan, bold = true }) - hi(0, "ModeMsg", { bold = true, fg = color.light_olive_green }) - hi(0, "MoreMsg", { bold = true, ctermfg = 121, fg = color.light_olive_green }) - hi(0, "NERDTreeFile", { fg = color.grey }) - hi(0, "NERDTreeCWD", { fg = color.grey }) - hi(0, "NERDTreeGitStatusIgnored", { ctermfg = 81, fg = color.medium_gray }) - hi(0, "NERDTreeGitStatusModified", { ctermfg = 224, fg = color.bright_sky }) - hi(0, "NERDTreeGitStatusRenamed", { ctermfg = 225, fg = color.light_blue }) - hi(0, "NERDTreeGitStatusUntracked", { ctermfg = 14, fg = color.medium_gray }) - hi(0, "NonText", { bold = true, ctermfg = 12, fg = color.medium_gray }) - hi(0, "Normal", { bg = color.dark, fg = color.grey }) - hi(0, "NormalFloat", { fg = color.grey }) - hi(0, "NormalNC", { fg = color.grey }) - hi(0, "NotifyDEBUGBody", { link = "Normal" }) - hi(0, "NotifyDEBUGBorder", { fg = color.bright_sky }) - hi(0, "NotifyDEBUGIcon", { fg = color.bright_sky }) - hi(0, "NotifyDEBUGTitle", { fg = color.bright_sky }) - hi(0, "NotifyERRORBody", { link = "Normal" }) - hi(0, "NotifyERRORBorder", { fg = color.red }) - hi(0, "NotifyERRORIcon", { fg = color.red }) - hi(0, "NotifyERRORTitle", { fg = color.red }) - hi(0, "NotifyINFOBody", { link = "Normal" }) - hi(0, "NotifyINFOBorder", { fg = color.grey }) - hi(0, "NotifyINFOIcon", { fg = color.grey }) - hi(0, "NotifyINFOTitle", { fg = color.grey }) - hi(0, "NotifyTRACEBody", { link = "Normal" }) - hi(0, "NotifyTRACEBorder", { fg = color.bright_sky }) - hi(0, "NotifyTRACEIcon", { fg = color.bright_sky }) - hi(0, "NotifyTRACETitle", { fg = color.bright_sky }) - hi(0, "NotifyWARNBody", { link = "Normal" }) - hi(0, "NotifyWARNBorder", { fg = color.pale_gold }) - hi(0, "NotifyWARNIcon", { fg = color.pale_gold }) - hi(0, "NotifyWARNTitle", { fg = color.pale_gold }) - hi(0, "Number", { fg = color.light_brown }) - hi(0, "NvimInternalError", { bg = color.red, ctermbg = 9, ctermfg = 9, fg = color.dark }) - hi(0, "Operator", { fg = color.grey }) - hi(0, "OutlineDetail", { fg = color._39 }) - hi(0, "OutlineFoldPrefix", { fg = color._54 }) - hi(0, "OutlineIndentEvn", { fg = color._53 }) - hi(0, "OutlineIndentOdd", { fg = color._55 }) - hi(0, "PreProc", { ctermfg = 81, fg = color.golden_yellow }) - hi(0, "Question", { bold = true, ctermfg = 121, fg = color.light_blue }) - hi(0, "QuickFixLine", { bg = color.background }) - hi(0, "References", { bold = true, fg = color.light_lavender }) - hi(0, "ReferencesIcon", { fg = color.bright_yellow_green }) - hi(0, "Repeat", { fg = color.golden_yellow }) - hi(0, "SagaShadow", { fg = color.dark }) - hi(0, "ScrollbarCursor", { ctermfg = 0, fg = color.grey }) - hi(0, "ScrollbarCursorHandle", { bg = color.background, ctermbg = 15, ctermfg = 0, fg = color.grey }) - hi(0, "ScrollbarError", { ctermfg = 0, fg = color.red }) - hi(0, "ScrollbarErrorHandle", { bg = color.background, ctermbg = 15, ctermfg = 0, fg = color.red }) - hi(0, "ScrollbarGitAdd", { ctermfg = 0, fg = color.green }) - hi(0, "ScrollbarGitAddHandle", { bg = color.background, ctermbg = 15, ctermfg = 0, fg = color.green }) - hi(0, "ScrollbarGitChange", { ctermfg = 0, fg = color.bright_yellow_green }) - hi( - 0, - "ScrollbarGitChangeHandle", - { bg = color.background, ctermbg = 15, ctermfg = 0, fg = color.bright_yellow_green } - ) - hi(0, "ScrollbarGitDelete", { ctermfg = 0, fg = color.red }) - hi(0, "ScrollbarGitDeleteHandle", { bg = color.background, ctermbg = 15, ctermfg = 0, fg = color.red }) - hi(0, "ScrollbarHandle", { bg = color.background, ctermbg = 15 }) - hi(0, "ScrollbarHint", { ctermfg = 0, fg = color.bright_sky }) - hi(0, "ScrollbarHintHandle", { bg = color.background, ctermbg = 15, ctermfg = 0, fg = color.bright_sky }) - hi(0, "ScrollbarInfo", { ctermfg = 0, fg = color.grey }) - hi(0, "ScrollbarInfoHandle", { bg = color.background, ctermbg = 15, ctermfg = 0, fg = color.grey }) - hi(0, "ScrollbarMisc", { ctermfg = 0, fg = color.grey }) - hi(0, "ScrollbarMiscHandle", { bg = color.background, ctermbg = 15, ctermfg = 0, fg = color.grey }) - hi(0, "ScrollbarSearch", { ctermfg = 0, fg = color.background }) - hi(0, "ScrollbarSearchHandle", { bg = color.background, ctermbg = 15, ctermfg = 0, fg = color.background }) - hi(0, "ScrollbarWarn", { ctermfg = 0, fg = color.pale_gold }) - hi(0, "ScrollbarWarnHandle", { bg = color.background, ctermbg = 15, ctermfg = 0, fg = color.pale_gold }) - hi(0, "Search", { bg = color.golden_yellow, ctermbg = 11, ctermfg = 0, fg = color.background }) - hi(0, "SignColumn", { ctermbg = 242, ctermfg = 14, fg = color.silver_gray }) - hi(0, "SniprunFloatingWinErr", { ctermfg = 1, fg = color._38 }) - hi(0, "SniprunFloatingWinOk", { ctermfg = 14, fg = color.bright_cyan }) - hi(0, "SniprunVirtualTextErr", { bg = color._38, ctermbg = 1, fg = color.dark }) - hi(0, "SniprunVirtualTextOk", { bg = color.bright_cyan, ctermbg = 14, fg = color.dark }) - hi(0, "Special", { ctermfg = 224, fg = color.bright_sky }) - hi(0, "SpecialChar", { fg = color.light_brown }) - hi(0, "SpecialKey", { ctermfg = 81, fg = color.medium_gray }) - hi(0, "SpellBad", { ctermbg = 9, sp = color.red, undercurl = true }) - hi(0, "SpellCap", { ctermbg = 12, sp = color.light_blue, undercurl = true }) - hi(0, "SpellLocal", { ctermbg = 14, sp = color.bright_sky, undercurl = true }) - hi(0, "SpellRare", { ctermbg = 13, sp = color.pale_gold, undercurl = true }) - hi(0, "Statement", { bold = true, ctermfg = 11, fg = color.red }) - hi(0, "StatusLine", { bg = color.dark_grey, fg = color.grey }) - hi(0, "StatusLineNC", { bg = color.background, fg = color.silver_gray }) - hi(0, "StorageClass", { fg = color.golden_yellow }) - hi(0, "String", { fg = color.light_olive_green }) - hi(0, "Structure", { fg = color.pale_gold }) - hi(0, "Substitute", { bg = color.golden_yellow, fg = color.background }) - hi(0, "SymbolsOutlineConnector", { fg = color.medium_gray }) - hi(0, "TSAnnotation", { fg = color.light_brown }) - hi(0, "TSAttribute", { fg = color.golden_yellow }) - hi(0, "TSBoolean", { fg = color.light_brown }) - hi(0, "TSCharacter", { fg = color.red }) - hi(0, "TSComment", { fg = color.comment, italic = true }) - hi(0, "GitSignsCurrentLineBlame", { fg = color.comment, italic = true }) - hi(0, "TSConditional", { fg = color.burnt_orange }) - hi(0, "TSConstBuiltin", { fg = color.light_brown, italic = true }) - hi(0, "TSMethodCall", { fg = color.pale_taupe }) - hi(0, "TSFunctionCall", { fg = color.pale_taupe }) - hi(0, "TSConstMacro", { fg = color.red }) - hi(0, "TSConstant", { fg = color.lavender }) - hi(0, "TSConstructor", { fg = color.light_blue }) - hi(0, "TSCurrentScope", { bold = true }) - hi(0, "TSDefinition", { sp = color.silver_gray, underline = true }) - hi(0, "TSDefinitionUsage", { sp = color.silver_gray, underline = true }) - hi(0, "TSEmphasis", { fg = color.light_brown, italic = true }) - hi(0, "TSError", { fg = color.red }) - hi(0, "TSException", { fg = color.red }) - hi(0, "TSField", { fg = color.grey }) - hi(0, "TSFloat", { fg = color.light_brown }) - hi(0, "TSFuncBuiltin", { fg = color.burnt_orange, italic = true }) - hi(0, "TSFuncMacro", { fg = color.red }) - hi(0, "TSFunction", { fg = color._58 }) - hi(0, "TSInclude", { fg = color.copper_brown }) - hi(0, "TSKeyword", { fg = color.burnt_orange }) - hi(0, "TSKeywordFunction", { fg = color.burnt_orange }) - hi(0, "TSKeywordOperator", { fg = color.pale_gold }) - hi(0, "TSLabel", { fg = color.lavender }) - hi(0, "TSLiteral", { fg = color.light_brown }) - hi(0, "TSMethod", { fg = color.pale_gold }) - hi(0, "TSNamespace", { fg = color._61 }) - hi(0, "TSNone", { fg = color.grey }) - hi(0, "TSNumber", { fg = color._68 }) - hi(0, "TSConstantBuiltin", { fg = color.copper_brown }) - hi(0, "TSOperator", { fg = color.grey }) - hi(0, "TSParameter", { fg = color.grey }) - hi(0, "TSParameterReference", { fg = color.grey }) - hi(0, "TSProperty", { fg = color.pale_gold }) - hi(0, "TSPunctBracket", { fg = color.grey }) - hi(0, "TSPunctDelimiter", { fg = color.light_brown }) - hi(0, "TSPunctSpecial", { fg = color.grey }) - hi(0, "TSRepeat", { fg = color.pale_gold }) - hi(0, "TSStrike", { fg = color.dark, strikethrough = true }) - hi(0, "TSString", { fg = color.olive_green }) - hi(0, "TSStringEscape", { fg = color.bright_sky }) - hi(0, "TSStringRegex", { fg = color.bright_sky }) - hi(0, "TSStrong", { bold = true }) - hi(0, "TSSymbol", { fg = color.light_olive_green }) - hi(0, "TSTag", { fg = color.golden_yellow }) - hi(0, "TSTagDelimiter", { fg = color.light_brown }) - hi(0, "TSText", { fg = color.grey }) - hi(0, "TSTitle", { fg = color.light_blue }) - hi(0, "TSType", { fg = color._66 }) - - hi(0, "TSTypeDefinition", { fg = color.grey }) - hi(0, "TSTypeBuiltin", { fg = color.burnt_orange, italic = true }) - hi(0, "TSURI", { fg = color.light_brown, underline = true }) - hi(0, "TSUnderline", { fg = color.dark, underline = true }) - hi(0, "TSVariable", { fg = color.grey }) - hi(0, "TSVariableBuiltin", { fg = color.burnt_orange, italic = true }) - hi(0, "TabLine", { bg = color.background, ctermbg = 242, ctermfg = 15, fg = color.medium_gray }) - hi(0, "TabLineFill", { bg = color.background, fg = color.medium_gray }) - hi(0, "TabLineSel", { bg = color.background, fg = color.light_olive_green }) - hi(0, "Tag", { fg = color.golden_yellow }) - hi(0, "TargetFileName", { fg = color._50 }) - -- telescope - if M.config.opt.integrations.telescope then - hi(0, "TelescopeBorder", { bg = color.very_dark_gray, fg = color.very_dark_gray }) - hi(0, "TelescopeNormal", { bg = color.very_dark_gray }) - hi(0, "TelescopePreviewLine", { bg = color.background }) - hi(0, "TelescopePreviewTitle", { bg = color.light_olive_green, fg = color.very_dark_gray }) - hi(0, "TelescopePromptBorder", { bg = color.dark_charcoal_gray, fg = color.dark_charcoal_gray }) - hi(0, "TelescopePromptNormal", { bg = color.dark_charcoal_gray, fg = color.grey }) - hi(0, "TelescopePromptPrefix", { bg = color.dark_charcoal_gray, fg = color.red }) - hi(0, "TelescopePromptTitle", { bg = color.red, fg = color.very_dark_gray }) - hi(0, "TelescopeResultsTitle", { bg = color.very_dark_gray, fg = color.very_dark_gray }) - hi(0, "TelescopeSelection", { bg = color.dark_charcoal_gray }) - end - - hi(0, "TermCursor", { bg = color.very_light_gray, fg = color.dark }) - hi(0, "TermCursorNC", { bg = color.very_light_gray, fg = color.dark }) - hi(0, "Title", { ctermfg = 225, fg = color.light_blue }) - hi(0, "Todo", { bg = color.background, ctermbg = 11, ctermfg = 0, fg = color.golden_yellow }) - hi(0, "TooLong", { fg = color.red }) - hi(0, "TreesitterContext", { bg = color.background, italic = true }) - hi(0, "Type", { ctermfg = 121, fg = color._66 }) - hi(0, "Typedef", { fg = color.golden_yellow }) - hi(0, "Underlined", { ctermfg = 81, fg = color.red, underline = true }) - hi(0, "User1", { bg = color.dark_grey, fg = color.red }) - hi(0, "User2", { bg = color.dark_grey, fg = color.pale_gold }) - hi(0, "User3", { bg = color.dark_grey, fg = color.grey }) - hi(0, "User4", { bg = color.dark_grey, fg = color.bright_sky }) - hi(0, "User5", { bg = color.dark_grey, fg = color.grey }) - hi(0, "User6", { bg = color.background, fg = color.grey }) - hi(0, "User7", { bg = color.dark_grey, fg = color.grey }) - hi(0, "User8", { bg = color.dark_grey, fg = color.dark }) - hi(0, "User9", { bg = color.dark_grey, fg = color.dark }) - hi(0, "VertSplit", { fg = color.grey }) - hi(0, "WinSeparator", { fg = color.grey }) - hi(0, "Visual", { bg = color.dark_grey, ctermbg = 242 }) - hi(0, "VisualNOS", { fg = color.red }) - hi(0, "WarningMsg", { ctermfg = 224, fg = color.red }) - hi(0, "WildMenu", { bg = color.golden_yellow, ctermbg = 11, ctermfg = 0, fg = color.red }) - hi(0, "WinBar", { fg = color.grey }) - hi(0, "WinBarNC", { fg = color.silver_gray }) - hi(0, "gitcommitBranch", { bold = true, fg = color.light_brown }) - hi(0, "gitcommitComment", { fg = color.medium_gray }) - hi(0, "gitcommitDiscarded", { fg = color.medium_gray }) - hi(0, "gitcommitDiscardedFile", { bold = true, fg = color.red }) - hi(0, "gitcommitDiscardedType", { fg = color.light_blue }) - hi(0, "gitcommitHeader", { fg = color.pale_gold }) - hi(0, "gitcommitOverflow", { fg = color.red }) - hi(0, "gitcommitSelected", { fg = color.medium_gray }) - hi(0, "gitcommitSelectedFile", { bold = true, fg = color.light_olive_green }) - hi(0, "gitcommitSelectedType", { fg = color.light_blue }) - hi(0, "gitcommitSummary", { fg = color.light_olive_green }) - hi(0, "gitcommitUnmergedFile", { bold = true, fg = color.red }) - hi(0, "gitcommitUnmergedType", { fg = color.light_blue }) - hi(0, "gitcommitUntracked", { fg = color.medium_gray }) - hi(0, "gitcommitUntrackedFile", { fg = color.golden_yellow }) - hi(0, "iCursor", { bg = color._72, fg = color.very_light_gray }) - hi(0, "lCursor", { bg = color.very_light_gray, fg = color.dark }) - - if M.config.opt.integrations.lualine then - hi(0, "lualine_a_command", { bg = color.green, bold = true, fg = color.dark }) - hi(0, "lualine_a_inactive", { bg = color.light_slate_gray, bold = true, fg = color.dark }) - hi(0, "lualine_a_insert", { bg = color.green, bold = true, fg = color.dark }) - hi(0, "lualine_a_normal", { bg = color.green, bold = true, fg = color.dark }) - hi(0, "lualine_a_replace", { bg = color.green, bold = true, fg = color.dark }) - hi(0, "lualine_a_visual", { bg = color.green, bold = true, fg = color.dark }) - hi(0, "lualine_b_command", { bg = color.green, fg = color.dark }) - hi(0, "lualine_b_diagnostics_error_command", { bg = color.green, fg = color.red }) - hi(0, "lualine_b_diagnostics_error_inactive", { bg = color.light_slate_gray, fg = color.red }) - hi(0, "lualine_b_diagnostics_error_insert", { bg = color.green, fg = color.red }) - hi(0, "lualine_b_diagnostics_error_normal", { bg = color.green, fg = color.red }) - hi(0, "lualine_b_diagnostics_error_replace", { bg = color.green, fg = color.red }) - hi(0, "lualine_b_diagnostics_error_terminal", { bg = color.green, fg = color.red }) - hi(0, "lualine_b_diagnostics_error_visual", { bg = color.green, fg = color.red }) - hi(0, "lualine_b_diagnostics_hint_command", { bg = color.green, fg = color.bright_sky }) - hi(0, "lualine_b_diagnostics_hint_inactive", { bg = color.light_slate_gray, fg = color.bright_sky }) - hi(0, "lualine_b_diagnostics_hint_insert", { bg = color.green, fg = color.bright_sky }) - hi(0, "lualine_b_diagnostics_hint_normal", { bg = color.green, fg = color.bright_sky }) - hi(0, "lualine_b_diagnostics_hint_replace", { bg = color.green, fg = color.bright_sky }) - hi(0, "lualine_b_diagnostics_hint_terminal", { bg = color.green, fg = color.bright_sky }) - hi(0, "lualine_b_diagnostics_hint_visual", { bg = color.green, fg = color.bright_sky }) - hi(0, "lualine_b_diagnostics_info_command", { bg = color.green, fg = color.grey }) - hi(0, "lualine_b_diagnostics_info_inactive", { bg = color.light_slate_gray, fg = color.grey }) - hi(0, "lualine_b_diagnostics_info_insert", { bg = color.green, fg = color.grey }) - hi(0, "lualine_b_diagnostics_info_normal", { bg = color.green, fg = color.grey }) - hi(0, "lualine_b_diagnostics_info_replace", { bg = color.green, fg = color.grey }) - hi(0, "lualine_b_diagnostics_info_terminal", { bg = color.green, fg = color.grey }) - hi(0, "lualine_b_diagnostics_info_visual", { bg = color.green, fg = color.grey }) - hi(0, "lualine_b_diagnostics_warn_command", { bg = color.green, fg = color.pale_gold }) - hi(0, "lualine_b_diagnostics_warn_inactive", { bg = color.light_slate_gray, fg = color.pale_gold }) - hi(0, "lualine_b_diagnostics_warn_insert", { bg = color.green, fg = color.pale_gold }) - hi(0, "lualine_b_diagnostics_warn_normal", { bg = color.green, fg = color.pale_gold }) - hi(0, "lualine_b_diagnostics_warn_replace", { bg = color.green, fg = color.pale_gold }) - hi(0, "lualine_b_diagnostics_warn_terminal", { bg = color.green, fg = color.pale_gold }) - hi(0, "lualine_b_diagnostics_warn_visual", { bg = color.green, fg = color.pale_gold }) - hi(0, "lualine_b_diff_added_command", { bg = color.green, fg = color.light_olive_green }) - hi(0, "lualine_b_diff_added_inactive", { bg = color.light_slate_gray, fg = color.light_olive_green }) - hi(0, "lualine_b_diff_added_insert", { bg = color.green, fg = color.light_olive_green }) - hi(0, "lualine_b_diff_added_normal", { bg = color.green, fg = color.light_olive_green }) - hi(0, "lualine_b_diff_added_replace", { bg = color.green, fg = color.light_olive_green }) - hi(0, "lualine_b_diff_added_terminal", { bg = color.green, fg = color.light_olive_green }) - hi(0, "lualine_b_diff_added_visual", { bg = color.green, fg = color.light_olive_green }) - hi(0, "lualine_b_diff_modified_command", { bg = color.green, fg = color.light_blue }) - hi(0, "lualine_b_diff_modified_inactive", { bg = color.light_slate_gray, fg = color.light_blue }) - hi(0, "lualine_b_diff_modified_insert", { bg = color.green, fg = color.light_blue }) - hi(0, "lualine_b_diff_modified_normal", { bg = color.green, fg = color.light_blue }) - hi(0, "lualine_b_diff_modified_replace", { bg = color.green, fg = color.light_blue }) - hi(0, "lualine_b_diff_modified_terminal", { bg = color.green, fg = color.light_blue }) - hi(0, "lualine_b_diff_modified_visual", { bg = color.green, fg = color.light_blue }) - hi(0, "lualine_b_diff_removed_command", { bg = color.green, fg = color.red }) - hi(0, "lualine_b_diff_removed_inactive", { bg = color.light_slate_gray, fg = color.red }) - hi(0, "lualine_b_diff_removed_insert", { bg = color.green, fg = color.red }) - hi(0, "lualine_b_diff_removed_normal", { bg = color.green, fg = color.red }) - hi(0, "lualine_b_diff_removed_replace", { bg = color.green, fg = color.red }) - hi(0, "lualine_b_diff_removed_terminal", { bg = color.green, fg = color.red }) - hi(0, "lualine_b_diff_removed_visual", { bg = color.green, fg = color.red }) - hi(0, "lualine_b_inactive", { bg = color.light_slate_gray, fg = color.dark }) - hi(0, "lualine_b_insert", { bg = color.green, fg = color.dark }) - hi(0, "lualine_b_normal", { bg = color.green, fg = color.dark }) - hi(0, "lualine_b_replace", { bg = color.green, fg = color.dark }) - hi(0, "lualine_b_visual", { bg = color.green, fg = color.dark }) - hi(0, "lualine_c_command", { bg = color.green, fg = color.dark }) - hi(0, "lualine_c_inactive", { bg = color.light_slate_gray, fg = color.dark }) - hi(0, "lualine_c_insert", { bg = color.green, fg = color.dark }) - hi(0, "lualine_c_normal", { bg = color.green, fg = color.dark }) - hi(0, "lualine_c_replace", { bg = color.green, fg = color.dark }) - hi(0, "lualine_c_visual", { bg = color.green, fg = color.dark }) - hi(0, "lualine_x_2_command", { bg = color.green, fg = color.peach_orange }) - hi(0, "lualine_x_2_inactive", { bg = color.light_slate_gray, fg = color.peach_orange }) - hi(0, "lualine_x_2_insert", { bg = color.green, fg = color.peach_orange }) - hi(0, "lualine_x_2_normal", { bg = color.green, fg = color.peach_orange }) - hi(0, "lualine_x_2_replace", { bg = color.green, fg = color.peach_orange }) - hi(0, "lualine_x_2_terminal", { bg = color.green, fg = color.peach_orange }) - hi(0, "lualine_x_2_visual", { bg = color.green, fg = color.peach_orange }) - hi(0, "lualine_x_filetype_DevIconDefault_command", { bg = color.green, fg = color.slate_gray }) - hi(0, "lualine_x_filetype_DevIconDefault_inactive", { bg = color.light_slate_gray, fg = color.slate_gray }) - hi(0, "lualine_x_filetype_DevIconDefault_insert", { bg = color.green, fg = color.slate_gray }) - hi(0, "lualine_x_filetype_DevIconDefault_normal", { bg = color.green, fg = color.slate_gray }) - hi(0, "lualine_x_filetype_DevIconDefault_replace", { bg = color.green, fg = color.slate_gray }) - hi(0, "lualine_x_filetype_DevIconDefault_terminal", { bg = color.green, fg = color.slate_gray }) - hi(0, "lualine_x_filetype_DevIconDefault_visual", { bg = color.green, fg = color.slate_gray }) - end - - -- nvim-ts-rainbow - hi(0, "rainbowcol1", { fg = color.very_light_gray }) - hi(0, "rainbowcol2", { fg = color.light_brown }) - hi(0, "rainbowcol3", { fg = color.golden_yellow }) - hi(0, "rainbowcol4", { fg = color.very_light_gray }) - hi(0, "rainbowcol5", { fg = color.bright_sky }) - hi(0, "rainbowcol6", { fg = color.light_blue }) - hi(0, "rainbowcol7", { fg = color.pale_gold }) - - hi(0, "@lsp.type.keyword.go", { link = "TSKeyword" }) - hi(0, "@lsp.type.string.go", { link = "TSString" }) - hi(0, "Statement", { link = "TSKeyword" }) - hi(0, "Comment", { link = "TSComment" }) - hi(0, "Number", { link = "TSNumber" }) - hi(0, "String", { link = "TSString" }) - hi(0, "goImportString", { link = "TSString" }) - hi(0, "@lsp.type.function", { link = "TSMethodCall" }) - hi(0, "@lsp.typemod.function.definition", { link = "TSFunction" }) - hi(0, "@lsp.type.method", { link = "TSMethod" }) - hi(0, "goBlock", { link = "TSVariable" }) - hi(0, "Identifier", { link = "TSKeyword" }) - -- Terminal colors - local g = vim.g - - g.terminal_color_0 = color.dark - g.terminal_color_1 = color.red - g.terminal_color_2 = color.light_olive_green - g.terminal_color_3 = color.golden_yellow - g.terminal_color_4 = color.light_blue - g.terminal_color_5 = color.pale_gold - g.terminal_color_6 = color.bright_sky - g.terminal_color_7 = color.very_light_gray - g.terminal_color_8 = color.medium_gray - g.terminal_color_9 = color.red - g.terminal_color_10 = color.light_olive_green - g.terminal_color_11 = color.golden_yellow - g.terminal_color_12 = color.light_blue - g.terminal_color_13 = color.pale_gold - g.terminal_color_14 = color.bright_sky - g.terminal_color_15 = color.very_light_gray - - -- Snacks Dashboard - hi(0, "SnacksDashboardHeader", { fg = color.golden_yellow, bold = true }) - hi(0, "SnacksDashboardTitle", { fg = color.pale_gold, bold = true }) - hi(0, "SnacksDashboardIcon", { fg = color.light_blue }) - hi(0, "SnacksDashboardDesc", { fg = color.light_slate_gray }) - hi(0, "SnacksDashboardFile", { fg = color.pale_gold, bold = true }) - hi(0, "SnacksDashboardKey", { fg = color.burnt_orange }) - hi(0, "SnacksDashboardSpecial", { fg = color.light_slate_gray }) - hi(0, "SnacksDashboardDir", { fg = color.light_slate_gray }) - hi(0, "SnacksDashboardNormal", { fg = color.light_slate_gray }) - hi(0, "SnacksDashboardTerminal", { fg = color.light_slate_gray }) - hi(0, "SnacksDashboardFooter", { fg = color.light_slate_gray }) - - -- Neo-Tree - hi(0, "NeoTreeFileName", { fg = color.light_slate_gray }) - hi(0, "NeoTreeDotfile", { fg = color.comment }) - hi(0, "NeoTreeDirectoryName", { fg = color.pale_gold }) - hi(0, "NeoTreeDirectoryIcon", { fg = color.pale_gold }) - hi(0, "NeoTreeGitModified", { fg = color.burnt_orange }) - hi(0, "NeoTreeGitStaged", { fg = color.olive_green }) - hi(0, "NeoTreeGitUntracked", { fg = color.lavender }) - hi(0, "NeoTreeNormal", { fg = color.light_slate_gray, bg = color.very_dark_gray }) - hi(0, "NeoTreeNormalNC", { fg = color.light_slate_gray, bg = color.very_dark_gray }) - hi(0, "NeoTreeTabActive", { fg = color.light_slate_gray, bg = color.very_dark_gray, bold = true }) - hi(0, "NeoTreeTabInactive", { fg = color.dark_grey, bg = color.very_dark_gray }) - hi(0, "NeoTreeTabSeparatorActive", { fg = color.light_slate_gray, bg = color.very_dark_gray }) - hi(0, "NeoTreeTabSeparatorInactive", { fg = color.light_slate_gray, bg = color.dark_grey }) -end - -return M diff --git a/nvim/lua/custom/init.lua b/nvim/lua/custom/init.lua deleted file mode 100644 index 202c395..0000000 --- a/nvim/lua/custom/init.lua +++ /dev/null @@ -1,19 +0,0 @@ --- ========== Telescope ============= -- -require("telescope").load_extension("noice") -require("telescope.themes").get_dropdown() - - --- ========== Theme ============= -- -require("custom.darcula").setup() - --- ========== Make ============= -- -require("custom.make") - --- ========== Formating ============= -- -vim.api.nvim_create_autocmd("BufWritePre", { - pattern = { "*.c", "*.cpp", "*.h", "*.hpp", "*.go" }, - callback = function() - vim.lsp.buf.format() - end, -}) - diff --git a/nvim/lua/custom/make.lua b/nvim/lua/custom/make.lua deleted file mode 100644 index a97b473..0000000 --- a/nvim/lua/custom/make.lua +++ /dev/null @@ -1,184 +0,0 @@ -_G.last_make_command = nil -_G.make_terminal_buf = nil -_G.build_targets = {} - -local config_file = vim.fn.stdpath('config') .. '/build_targets.json' - --- Загрузка таргетов из файла -local function load_targets() - local ok, data = pcall(vim.fn.readfile, config_file) - if ok and data[1] then - _G.build_targets = vim.fn.json_decode(data[1]) - else - _G.build_targets = {} - end -end - --- Сохранение таргетов в файл -local function save_targets() - local data = vim.fn.json_encode(_G.build_targets) - vim.fn.writefile({data}, config_file) -end - --- Загружаем таргеты при старте -load_targets() - -local function run_make_command(command) - if _G.make_terminal_buf and vim.api.nvim_buf_is_valid(_G.make_terminal_buf) then - vim.cmd('buffer ' .. _G.make_terminal_buf) - else - vim.cmd('terminal') - _G.make_terminal_buf = vim.api.nvim_get_current_buf() - end - vim.cmd('startinsert') - vim.defer_fn(function() - if vim.b.terminal_job_id then - vim.fn.chansend(vim.b.terminal_job_id, "clear\n") - vim.fn.chansend(vim.b.terminal_job_id, command .. "\n") - end - end, 300) -end - --- Основная команда сборки (оставьте вашу текущую) -vim.api.nvim_create_user_command('Build', function() - vim.ui.input({ - prompt = 'Флаги сборки: ', - default = '', - }, function(flags) - if flags == nil then return end - vim.ui.input({ - prompt = 'Имя проекта: ', - default = '', - }, function(project_name) - if project_name == nil then return end - local make_cmd = "meson compile" .. flags .. " " .. project_name - _G.last_make_command = make_cmd - run_make_command(make_cmd) - vim.notify("🔨 Сборка запущена: " .. make_cmd) - end) - end) -end, { - desc = "Сборка проекта в терминале" -}) - -vim.api.nvim_create_user_command('TargetNew', function() - vim.ui.input({ - prompt = 'Название таргета: ', - default = '', - }, function(target_name) - if target_name == nil or target_name == '' then return end - vim.ui.input({ - prompt = 'Команда сборки для "' .. target_name .. '": ', - default = '', - }, function(build_command) - if build_command == nil or build_command == '' then return end - _G.build_targets[target_name] = build_command - save_targets() - vim.notify("✅ Таргет '" .. target_name .. "' сохранен") - end) - end) -end, { - desc = "Создать новый таргет сборки" -}) - --- ПЕРЕПИСАННАЯ команда для выбора таргета с использованием vim.ui.select -vim.api.nvim_create_user_command('Target', function() - local target_count = 0 - for _ in pairs(_G.build_targets) do - target_count = target_count + 1 - end - if target_count == 0 then - vim.notify("❌ Нет сохраненных таргетов. Используйте :TargetNew", vim.log.levels.ERROR) - return - end - -- Подготавливаем список для vim.ui.select - local targets_list = {} - for name, cmd in pairs(_G.build_targets) do - table.insert(targets_list, { - name = name, - cmd = cmd, - -- Форматируем для красивого отображения - display = string.format("🔨 %s\n 📝 %s", name, cmd) - }) - end - -- Сортируем по имени - table.sort(targets_list, function(a, b) return a.name < b.name end) - vim.ui.select(targets_list, { - prompt = '📋 Выберите таргет сборки:', - format_item = function(item) - return item.display - end, - }, function(selected) - if not selected then - vim.notify("❌ Выбор отменен", vim.log.levels.WARN) - return - end - _G.last_make_command = selected.cmd - run_make_command(selected.cmd) - vim.notify("🔨 Запускаю: " .. selected.cmd) - end) -end, { - desc = "Выбрать таргет сборки" -}) - --- Команда для просмотра всех таргетов -vim.api.nvim_create_user_command('TargetList', function() - local target_count = 0 - for _ in pairs(_G.build_targets) do - target_count = target_count + 1 - end - if target_count == 0 then - print("📝 Список таргетов пуст") - return - end - print("📋 Сохраненные таргеты сборки:") - local targets_list = {} - for name, cmd in pairs(_G.build_targets) do - table.insert(targets_list, { name = name, cmd = cmd }) - end - table.sort(targets_list, function(a, b) return a.name < b.name end) - for i, target in ipairs(targets_list) do - print(string.format(" %d. %s → %s", i, target.name, target.cmd)) - end -end, { - desc = "Показать список всех таргетов" -}) - --- Команда для удаления таргета (уже использует vim.ui.select - оставляем как есть) -vim.api.nvim_create_user_command('TargetDelete', function() - local target_count = 0 - for _ in pairs(_G.build_targets) do - target_count = target_count + 1 - end - if target_count == 0 then - vim.notify("❌ Нет сохраненных таргетов", vim.log.levels.ERROR) - return - end - local targets_list = {} - for name, cmd in pairs(_G.build_targets) do - table.insert(targets_list, name) - end - table.sort(targets_list) - vim.ui.select(targets_list, { - prompt = 'Выберите таргет для удаления:', - }, function(selected) - if not selected then return end - _G.build_targets[selected] = nil - save_targets() - vim.notify("🗑️ Таргет '" .. selected .. "' удален") - end) -end, { - desc = "Удалить таргет сборки" -}) - --- Повтор последней сборки (оставьте вашу текущую) -vim.api.nvim_create_user_command('LastBuild', function() - if _G.last_make_command then - run_make_command(_G.last_make_command) - vim.notify("🔁 Повторяю: " .. _G.last_make_command) - else - vim.notify("❌ Нет истории сборок", vim.log.levels.ERROR) - end -end, { - desc = "Повторить последнюю сборку в терминале" -}) diff --git a/nvim/lua/mappings.lua b/nvim/lua/mappings.lua deleted file mode 100644 index 1d24361..0000000 --- a/nvim/lua/mappings.lua +++ /dev/null @@ -1,109 +0,0 @@ -local map = vim.keymap.set - --- ========== Basics =========== -- -map("n", ";", ":", { desc = "CMD enter command mode" }) -map("i", "jk", "") -map("t", "jk", "") -map("n", "h", "s | terminal | i"); - --- ========== Debug =========== -- -map('n', 'db', 'DapToggleBreakpoint', { desc = 'Toggle breakpoint' }) -map('n', 'dr', 'DapContinue', { desc = 'Start/continue debug' }) -map('n', 'ds', 'DapStepOver', { desc = 'Step over' }) -map('n', 'di', 'DapStepInto', { desc = 'Step into' }) -map('n', 'do', 'DapStepOut', { desc = 'Step out' }) -map('n', 'dq', 'DapTerminate', { desc = 'Stop debug' }) -map('n', 'du', 'lua require("dapui").toggle()', { desc = 'Toggle DAP UI' }) - --- ========== LSP =========== -- -map('n', 'lo', 'lua vim.diagnostic.open_float()', { noremap = true, silent = true, desc = 'Open diagnostic' }) -map("n", "ll", 'lua vim.lsp.buf.code_action()', { noremap = true, silent = true, desc = 'Show complete by lsp'}) -map('n', '[l', 'DapContinue', { noremap = true, silent = true, desc = 'Go to prev diagnostic' }) -map('n', ']l', 'DapStepOver', { noremap = true, silent = true, desc = 'Go to next diagnostic' }) -map('n', 'lt', 'DapStepInto', { noremap = true, silent = true, desc = 'Open toggle' }) -map("n", "ds", vim.diagnostic.setloclist, { desc = "LSP diagnostic loclist" }) -map("n", "", "noh", { desc = "general clear highlights" }) - --- ========== Sessions ============= -- -map("n", "ss", ":SessionSave", {noremap = true, silent = true}) -map("n", "sl", ":SessionLoad", {noremap = true, silent = true}) -map("n", "st", ":Telescope persisted", {noremap = true, silent = true}) - --- ========== Window moves ============= -- -map("n", "", "h", { desc = "switch window left" }) -map("n", "", "l", { desc = "switch window right" }) -map("n", "", "j", { desc = "switch window down" }) -map("n", "", "k", { desc = "switch window up" }) - --- ========== Line moves ============= -- -map("i", "", "^i", { desc = "move beginning of line" }) -map("i", "", "", { desc = "move end of line" }) -map("i", "", "", { desc = "move left" }) -map("i", "", "", { desc = "move right" }) -map("i", "", "", { desc = "move down" }) -map("i", "", "", { desc = "move up" }) - --- ========== Comments ============= -- -map("n", "/", "gcc", { desc = "toggle comment", remap = true }) -map("v", "/", "gc", { desc = "toggle comment", remap = true }) - --- ========== Nvim-tree ============= -- -map("n", "", "NvimTreeToggle", { desc = "nvimtree toggle window" }) -map("n", "e", "NvimTreeFocus", { desc = "nvimtree focus window" }) - --- ========== Telescope ============= -- -map("n", "fw", "Telescope live_grep", { desc = "telescope live grep" }) -map("n", "fb", "Telescope buffers", { desc = "telescope find buffers" }) -map("n", "fh", "Telescope help_tags", { desc = "telescope help page" }) -map("n", "ma", "Telescope marks", { desc = "telescope find marks" }) -map("n", "fo", "Telescope oldfiles", { desc = "telescope find oldfiles" }) -map("n", "fz", "Telescope current_buffer_fuzzy_find", { desc = "telescope find in current buffer" }) -map("n", "cm", "Telescope git_commits", { desc = "telescope git commits" }) -map("n", "gt", "Telescope git_status", { desc = "telescope git status" }) -map("n", "pt", "Telescope terms", { desc = "telescope pick hidden term" }) -map("n", "ff", "Telescope find_files", { desc = "telescope find files" }) -map("n", "fa", "Telescope find_files follow=true no_ignore=true hidden=true", { desc = "telescope find all files" }) - --- ========== Which-key ============= -- -map("n", "wK", "WhichKey ", { desc = "whichkey all keymaps" }) - --- ========== Buffers ============= -- -map("n", "x", function() - local bufnr = vim.api.nvim_get_current_buf() - local buftype = vim.api.nvim_buf_get_option(bufnr, 'buftype') - local modified = vim.api.nvim_buf_get_option(bufnr, 'modified') - - if buftype == 'terminal' then - vim.cmd('bp | sp | bn | bd!') - return - end - - if modified then - vim.notify("Changes not saved") - else - vim.cmd('bp | sp | bn | bd') - end -end, {desc = "Close buffer"}) -map("n", "e", "enew", {desc = "Create buffer"}) -map("n", "", "BufferLineCycleNext", {desc = "Go to next buffer"}) -map("n", "", "BufferLineCyclePrev", {desc = "Go to prev buffer"}) - --- ========== Git ============= -- -map("n", "gb", "Gitsigns blame", {desc = "Open blame for file"}) -map("n", "gl", "Gitsigns blame", {desc = "Open blame for file"}) -map("n", "gco", "GitConflictChooseOurs", {desc = "Select the current changes"}) -map("n", "gct", "GitConflictChooseTheirs", {desc = "Select the incoming changes"}) -map("n", "gcn", "GitConflictNextConflict", {desc = "Move to the next conflict"}) -map("n", "gcp", "GitConflictPrevConflict", {desc = "Move to the previous conflict"}) -map("n", "ghn", "Gitsigns blame", {desc = "Show hunk in normal mode"}) -map("n", "ghi", "Gitsigns blame", {desc = "Show hunk inline"}) -map("n", "gd", "Gitsigns diffthis", {desc = "Show diff of buffer"}) -map("n", "gs", "Gitsigns stage_buffer", {desc = "Stage this buffer"}) -map("n", "gu", "Gitui", {desc = "Stage this buffer"}) - --- ========== Target ============= -- -map("n", "tt", "Build", {desc = "Build project"}) -map("n", "tt", "Target", {desc = "Execute target"}) -map("n", "tn", "TargetNew", {desc = "Create new target"}) -map("n", "tl", "TargetList", {desc = "Show list of targets"}) -map("n", "td", "TargetDelete", {desc = "Delete target from list"}) diff --git a/nvim/lua/options.lua b/nvim/lua/options.lua deleted file mode 100644 index 47c9476..0000000 --- a/nvim/lua/options.lua +++ /dev/null @@ -1,57 +0,0 @@ -local opt = vim.opt -local o = vim.o -local g = vim.g - --------------------------------------- options ------------------------------------------ -o.laststatus = 3 -o.showmode = false -o.splitkeep = "screen" - -o.clipboard = "unnamedplus" -o.cursorline = true -o.cursorlineopt = "number" - --- Indenting -o.expandtab = true -o.shiftwidth = 2 -o.smartindent = true -o.tabstop = 2 -o.softtabstop = 2 - -opt.fillchars = { eob = " " } -o.ignorecase = true -o.smartcase = true -o.mouse = "a" - --- Numbers -o.number = true -o.numberwidth = 2 -o.ruler = false - --- disable nvim intro -opt.shortmess:append "sI" - -o.signcolumn = "yes" -o.splitbelow = true -o.splitright = true -o.timeoutlen = 400 -o.undofile = true - --- interval for writing swap file to disk, also used by gitsigns -o.updatetime = 250 - --- go to previous/next line with h,l,left arrow and right arrow --- when cursor reaches end/beginning of line -opt.whichwrap:append "<>[]hl" - --- disable some default providers -g.loaded_node_provider = 0 -g.loaded_python3_provider = 0 -g.loaded_perl_provider = 0 -g.loaded_ruby_provider = 0 - --- add binaries installed by mason.nvim to path -local is_windows = vim.fn.has "win32" ~= 0 -local sep = is_windows and "\\" or "/" -local delim = is_windows and ";" or ":" -vim.env.PATH = table.concat({ vim.fn.stdpath "data", "mason", "bin" }, sep) .. delim .. vim.env.PATH diff --git a/nvim/lua/plugins/common.lua b/nvim/lua/plugins/common.lua deleted file mode 100644 index 013c40a..0000000 --- a/nvim/lua/plugins/common.lua +++ /dev/null @@ -1,76 +0,0 @@ -return { - -- Dev icons - { - "nvim-tree/nvim-web-devicons", - opts = {}, - }, - { - 'nvim-mini/mini.nvim', - version = '*' - }, - -- Marks - { - "chentoast/marks.nvim", - event = "VeryLazy", - opts = {}, - }, - -- Git - { - "lewis6991/gitsigns.nvim", - event = {"BufReadPre", "BufNewFile"}, - opts = function() - require("configs.gitsigns") - end, - }, - { - 'akinsho/git-conflict.nvim', - version = "*", - config = true - }, - -- Nvim tree - { - "nvim-tree/nvim-tree.lua", - cmd = { "NvimTreeToggle", "NvimTreeFocus" }, - opts = function() - return require "configs.nvimtree" - end, - }, - -- Pairs - { - "nvim-mini/mini.pairs", - event = { "BufReadPost", "BufNewFile" }, - opts = { - modes = { insert = true, command = true, terminal = false }, - skip_next = [=[[%w%%%'%[%"%.%`%$]]=], - skip_ts = { "string" }, - skip_unbalanced = true, - markdown = true, - }, - - }, - -- Formating - { - "stevearc/conform.nvim", - event = 'BufWritePre', - config = function() - require "configs.conform" - end, - }, - -- Yank highlight - { - "machakann/vim-highlightedyank", - event = "VeryLazy", - }, - -- Sessions - { - "olimorris/persisted.nvim", - event = "BufReadPre", - opts = { - autostart = true, - autosave = true, - save_dir = vim.fn.expand(vim.fn.stdpath("data") .. "/sessions/"), - use_git_branch = true, - autoload = false, - }, - }, -} diff --git a/nvim/lua/plugins/development.lua b/nvim/lua/plugins/development.lua deleted file mode 100644 index f54aa95..0000000 --- a/nvim/lua/plugins/development.lua +++ /dev/null @@ -1,141 +0,0 @@ -return { - -- Nvim lspconfig - { - "neovim/nvim-lspconfig", - event = { "BufReadPre", "BufNewFile" }, - config = function () - require("configs.lsp.lspconfig") - end - }, - -- Mason - { - "mason-org/mason.nvim", - opts = {} - }, - -- Mason lspconfig - { - "mason-org/mason-lspconfig.nvim", - opts = {}, - dependencies = { - "mason-org/mason.nvim", - "neovim/nvim-lspconfig", - } - }, - -- Nvim complete - { - "hrsh7th/nvim-cmp", - event = "InsertEnter", - dependencies = { - { - "L3MON4D3/LuaSnip", - dependencies = "rafamadriz/friendly-snippets", - opts = { history = true, updateevents = "TextChanged,TextChangedI" }, - config = function(_, opts) - require("luasnip").config.set_config(opts) - require "configs.luasnip" - end, - }, - { - "windwp/nvim-autopairs", - opts = { - fast_wrap = {}, - disable_filetype = { "TelescopePrompt", "vim" }, - }, - config = function(_, opts) - require("nvim-autopairs").setup(opts) - -- setup cmp for autopairs - local cmp_autopairs = require "nvim-autopairs.completion.cmp" - require("cmp").event:on("confirm_done", cmp_autopairs.on_confirm_done()) - end, - }, - { - "saadparwaiz1/cmp_luasnip", - "hrsh7th/cmp-nvim-lua", - "hrsh7th/cmp-nvim-lsp", - "hrsh7th/cmp-buffer", - "https://codeberg.org/FelipeLema/cmp-async-path.git" - } - }, - opts = function() - return require "configs.cmp" - end, - }, - -- Treesitter (syntax) - { - "nvim-treesitter/nvim-treesitter", - event = { "BufReadPost", "BufNewFile" }, - cmd = { "TSInstall", "TSBufEnable", "TSBufDisable", "TSModuleInfo" }, - build = ":TSUpdate", - config = function() - require("nvim-treesitter.config").setup(require "configs.treesitter") - end, - }, - -- Folders - { - 'kevinhwang91/nvim-ufo', - dependencies = 'kevinhwang91/promise-async', - event = "VeryLazy", - config = function() - require("configs.ufo") - end - }, - -- Tests - { - "nvim-neotest/neotest", - event = "VeryLazy", - dependencies = { - "nvim-lua/plenary.nvim", - "alfaix/neotest-gtest", - "olimorris/neotest-phpunit", - }, - config = function() - require("neotest").setup({ - adapters = { - require("neotest-phpunit"), - require("neotest-gtest").setup({}), - }, - }) - end, - }, - -- These are for C/C++ Debbuger - { - "nvim-neotest/nvim-nio", - event = "VeryLazy", - }, - { - "mfussenegger/nvim-dap", - event = "VeryLazy", - config = function () - require("configs.nvim-dap").setup() - end - }, - { - "rcarriga/nvim-dap-ui", - event = "VeryLazy", - dependencies = "mfussenegger/nvim-dap", - }, - { - "jay-babu/mason-nvim-dap.nvim", - event = "VeryLazy", - dependencies = { - "williamboman/mason.nvim", - "mfussenegger/nvim-dap", - }, - opts = { - handlers = {} - }, - }, - { - "theHamsta/nvim-dap-virtual-text", - dependencies = "mfussenegger/nvim-dap", - config = function() - require("nvim-dap-virtual-text").setup() - end, - }, - { - 'aspeddro/gitui.nvim', - config = function () - require("gitui").setup() - end, - }, -} diff --git a/nvim/lua/plugins/lines.lua b/nvim/lua/plugins/lines.lua deleted file mode 100644 index f013eca..0000000 --- a/nvim/lua/plugins/lines.lua +++ /dev/null @@ -1,17 +0,0 @@ -return { - { - 'nvim-lualine/lualine.nvim', - dependencies = { 'nvim-tree/nvim-web-devicons' }, - config = function() - require("configs.lualine") - end, - }, - { - 'akinsho/bufferline.nvim', - version = "*", - dependencies = 'nvim-tree/nvim-web-devicons', - config = function() - require("configs.bufferline") - end, - }, -} diff --git a/nvim/lua/plugins/noice.lua b/nvim/lua/plugins/noice.lua deleted file mode 100644 index bf05981..0000000 --- a/nvim/lua/plugins/noice.lua +++ /dev/null @@ -1,30 +0,0 @@ -return { - "folke/noice.nvim", - event = "VeryLazy", - opts ={ - -- add any options here - }, - dependencies = { - "MunifTanjim/nui.nvim", - "rcarriga/nvim-notify", - }, - config = { - lsp = { - signature = { - enabled = false, - }, - hover = { - enabled = false, - }, - override = { - ["vim.lsp.util.convert_input_to_markdown_lines"] = true, - ["vim.lsp.util.stylize_markdown"] = true, - }, - }, - presets = { - long_message_to_split = true, -- long messages will be sent to a split - inc_rename = false, -- enables an input dialog for inc-rename.nvim - lsp_doc_border = false, -- add a border to hover docs and signature help - }, - } -} diff --git a/nvim/lua/plugins/snacks.lua b/nvim/lua/plugins/snacks.lua deleted file mode 100644 index 1666073..0000000 --- a/nvim/lua/plugins/snacks.lua +++ /dev/null @@ -1,20 +0,0 @@ -return { - "folke/snacks.nvim", - priority = 1000, - lazy = false, - ---@type snacks.Config - opts = { - bigfile = { enabled = true }, - dashboard = { enabled = true, }, - explorer = { enabled = false }, - indent = { enabled = true }, - input = { enabled = true }, - picker = { enabled = true }, - notifier = { enabled = true }, - quickfile = { enabled = true }, - scope = { enabled = true }, - scroll = { enabled = true }, - statuscolumn = { enabled = true }, - words = { enabled = true }, - }, -} diff --git a/nvim/lua/plugins/telescope.lua b/nvim/lua/plugins/telescope.lua deleted file mode 100644 index d696d4b..0000000 --- a/nvim/lua/plugins/telescope.lua +++ /dev/null @@ -1,8 +0,0 @@ -return { - "nvim-telescope/telescope.nvim", - dependencies = { "nvim-treesitter/nvim-treesitter" }, - cmd = "Telescope", - configs = function() - return require "configs.telescope" - end, -} diff --git a/nvim/lua/plugins/typst.lua b/nvim/lua/plugins/typst.lua deleted file mode 100644 index c397840..0000000 --- a/nvim/lua/plugins/typst.lua +++ /dev/null @@ -1,8 +0,0 @@ -return { - 'chomosuke/typst-preview.nvim', - lazy = false, - version = '1.*', - opts = { - port = 8000, - }, -} diff --git a/nvim/lua/plugins/whichkey.lua b/nvim/lua/plugins/whichkey.lua deleted file mode 100644 index 9400187..0000000 --- a/nvim/lua/plugins/whichkey.lua +++ /dev/null @@ -1,67 +0,0 @@ -return { - "folke/which-key.nvim", - event = "VeryLazy", - opts_extend = { "spec" }, - opts = { - preset = "helix", - defaults = {}, - spec = { - { - mode = { "n", "x" }, - { "", group = "tabs" }, - { "c", group = "code" }, - { "d", group = "debug" }, - { "dp", group = "profiler" }, - { "f", group = "file/find" }, - { "g", group = "git" }, - { "gh", group = "hunks" }, - { "q", group = "quit/session" }, - { "s", group = "search" }, - { "u", group = "ui" }, - { "x", group = "diagnostics/quickfix" }, - { "[", group = "prev" }, - { "]", group = "next" }, - { "g", group = "goto" }, - { "gs", group = "surround" }, - { "z", group = "fold" }, - { - "b", - group = "buffer", - expand = function() - return require("which-key.extras").expand.buf() - end, - }, - { - "w", - group = "windows", - proxy = "", - expand = function() - return require("which-key.extras").expand.win() - end, - }, - -- better descriptions - { "gx", desc = "Open with system app" }, - }, - }, - }, - keys = { - { - "?", - function() - require("which-key").show({ global = false }) - end, - desc = "Buffer Keymaps (which-key)", - }, - { - "", - function() - require("which-key").show({ keys = "", loop = true }) - end, - desc = "Window Hydra Mode (which-key)", - }, - }, - config = function(_, opts) - local wk = require("which-key") - wk.setup(opts) - end, -} diff --git a/nvim/stylua.toml b/nvim/stylua.toml deleted file mode 100644 index ecb6dca..0000000 --- a/nvim/stylua.toml +++ /dev/null @@ -1,6 +0,0 @@ -column_width = 120 -line_endings = "Unix" -indent_type = "Spaces" -indent_width = 2 -quote_style = "AutoPreferDouble" -call_parentheses = "None" diff --git a/nvim/temp b/nvim/temp deleted file mode 100644 index 97b7eb0..0000000 --- a/nvim/temp +++ /dev/null @@ -1,34 +0,0 @@ -  Error 12:14:10 PM notify.error -lazy.nvim - -Failed to run `config` for nvim-treesitter - -/home/hhhh/.config/nvim/lua/plugins/development.lua:73: module 'nvim-treesitter.configs' not found: - no field package.preload['nvim-treesitter.configs'] - cache_loader: module 'nvim-treesitter.configs' not found - cache_loader_lib: module 'nvim-treesitter.configs' not found - no file './nvim-treesitter/configs.lua' - no file '/usr/share/luajit-2.1/nvim-treesitter/configs.lua' - no file '/usr/local/share/lua/5.1/nvim-treesitter/configs.lua' - no file '/usr/local/share/lua/5.1/nvim-treesitter/configs/init.lua' - no file '/usr/share/lua/5.1/nvim-treesitter/configs.lua' - no file '/usr/share/lua/5.1/nvim-treesitter/configs/init.lua' - no file '/home/hhhh/.local/share/nvim/lazy-rocks/telescope.nvim/share/lua/5.1/nvim-treesitter/configs.lua' - no file '/home/hhhh/.local/share/nvim/lazy-rocks/telescope.nvim/share/lua/5.1/nvim-treesitter/configs/init.lua' - no file './nvim-treesitter/configs.so' - no file '/usr/local/lib/lua/5.1/nvim-treesitter/configs.so' - no file '/usr/lib/lua/5.1/nvim-treesitter/configs.so' - no file '/usr/local/lib/lua/5.1/loadall.so' - no file '/home/hhhh/.local/share/nvim/lazy-rocks/telescope.nvim/lib/lua/5.1/nvim-treesitter/configs.so' - no file '/home/hhhh/.local/share/nvim/lazy-rocks/telescope.nvim/lib64/lua/5.1/nvim-treesitter/configs.so' - no file './nvim-treesitter.so' - no file '/usr/local/lib/lua/5.1/nvim-treesitter.so' - no file '/usr/lib/lua/5.1/nvim-treesitter.so' - no file '/usr/local/lib/lua/5.1/loadall.so' - no file '/home/hhhh/.local/share/nvim/lazy-rocks/telescope.nvim/lib/lua/5.1/nvim-treesitter.so' - no file '/home/hhhh/.local/share/nvim/lazy-rocks/telescope.nvim/lib64/lua/5.1/nvim-treesitter.so' - -# stacktrace: - - lua/plugins/development.lua:73 _in_ **config** - - lua/custom/init.lua:2 - - init.lua:11