diff --git a/lvim/config.lua b/lvim/config.lua deleted file mode 100644 index ecde990..0000000 --- a/lvim/config.lua +++ /dev/null @@ -1,24 +0,0 @@ --- Read the docs: https://www.lunarvim.org/docs/configuration --- Example configs: https://github.com/LunarVim/starter.lvim --- Video Tutorials: https://www.youtube.com/watch?v=sFA9kX-Ud_c&list=PLhoH5vyxr6QqGu0i7tt_XoVK9v-KvZ3m6 --- Forum: https://www.reddit.com/r/lunarvim/ --- Discord: https://discord.com/invite/Xb9B4Ny - -lvim.colorscheme = "melange" -lvim.builtin.breadcrumbs.active = false - -lvim.lsp.automatic_servers_installation = false -lvim.lsp.automatic_configuration.skipped_servers = { "rust_analyzer" } - -require "plugins.init" -require "mappings" -require "configs.nvimtree" -require "configs.bufferline" -require "configs.dropbar" -require "configs.dap" -require "configs.acmp" -require "configs.gitsigns" -require "configs.colorizer" -require "configs.autotag" -require "configs.prettier" -require "configs.nvimufo" diff --git a/lvim/lazy-lock.json b/lvim/lazy-lock.json deleted file mode 100755 index 021e50c..0000000 --- a/lvim/lazy-lock.json +++ /dev/null @@ -1,79 +0,0 @@ -{ - "Comment.nvim": { "branch": "master", "commit": "0236521ea582747b58869cb72f70ccfa967d2e89" }, - "LuaSnip": { "branch": "master", "commit": "1def35377854535bb3b0f4cc7a33c083cdb12571" }, - "alpha-nvim": { "branch": "main", "commit": "29074eeb869a6cbac9ce1fbbd04f5f5940311b32" }, - "bigfile.nvim": { "branch": "main", "commit": "33eb067e3d7029ac77e081cfe7c45361887a311a" }, - "bufferline.nvim": { "branch": "main", "commit": "73edc1f2732678e7a681e3d3be49782610914f6b" }, - "catppuccin": { "branch": "main", "commit": "9e6ec281f58038e5b30ce9a8828e6f9f9d744a27" }, - "cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" }, - "cmp-nvim-lsp": { "branch": "main", "commit": "39e2eda76828d88b773cc27a3f61d2ad782c922d" }, - "cmp-nvim-lua": { "branch": "main", "commit": "f12408bdb54c39c23e67cab726264c10db33ada8" }, - "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" }, - "cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" }, - "diffview.nvim": { "branch": "main", "commit": "4516612fe98ff56ae0415a259ff6361a89419b0a" }, - "dropbar.nvim": { "branch": "master", "commit": "669e325489202ae4da5a951314bbf8dbb20e7cff" }, - "friendly-snippets": { "branch": "main", "commit": "dd2fd1281d4b22e7b4a5bfafa3e142d958e251f2" }, - "fzf-lua": { "branch": "main", "commit": "ace9968be267b034e450be4feaf6e9107bc34fbd" }, - "gitsigns.nvim": { "branch": "main", "commit": "805610a9393fa231f2c2b49cb521bfa413fadb3d" }, - "huez.nvim": { "branch": "main", "commit": "3a4c75fa3ad5e5461749b886f262c82a4a239133" }, - "hybrid.nvim": { "branch": "master", "commit": "8838621a2e299582a0af5b8b96d5515f27b5d058" }, - "indent-blankline.nvim": { "branch": "master", "commit": "9637670896b68805430e2f72cf5d16be5b97a22a" }, - "kanagawa.nvim": { "branch": "master", "commit": "f491b0fe68fffbece7030181073dfe51f45cda81" }, - "lazy.nvim": { "branch": "main", "commit": "8f19915175395680808de529e4220da8dafc0759" }, - "lir.nvim": { "branch": "master", "commit": "7a9d45de08fecd23a04aca1f96688d744830029e" }, - "lualine.nvim": { "branch": "master", "commit": "0a5a66803c7407767b799067986b4dc3036e1983" }, - "lunar.nvim": { "branch": "master", "commit": "08bbc93b96ad698d22fc2aa01805786bcedc34b9" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "a4caa0d083aab56f6cd5acf2d42331b74614a585" }, - "mason.nvim": { "branch": "main", "commit": "49ff59aded1047a773670651cfa40e76e63c6377" }, - "material.nvim": { "branch": "main", "commit": "ac8f02e97e359b7d258c0a00ec0949fe880790ad" }, - "melange-nvim": { "branch": "master", "commit": "706a33f0a883fae9ec00ad648586792248a0575e" }, - "monokai-pro.nvim": { "branch": "master", "commit": "4f4133601296881bb2197800bd68d2bba9eaadb9" }, - "monokai.nvim": { "branch": "master", "commit": "b8bd44d5796503173627d7a1fc51f77ec3a08a63" }, - "neo-tree.nvim": { "branch": "v2.x", "commit": "80dc74d081823649809f78370fa5b204aa9a853a" }, - "neodev.nvim": { "branch": "main", "commit": "ce9a2e8eaba5649b553529c5498acb43a6c317cd" }, - "neogit": { "branch": "master", "commit": "d55bf6114c6cfba013e4c0e817e29e7752554ab7" }, - "nlsp-settings.nvim": { "branch": "main", "commit": "d92035e6c05cded5f1a7458b57506adbf29a5c9c" }, - "noice.nvim": { "branch": "main", "commit": "df448c649ef6bc5a6a633a44f2ad0ed8d4442499" }, - "none-ls.nvim": { "branch": "main", "commit": "3a4826687da4310af379515086d71faca4d21288" }, - "nord.nvim": { "branch": "main", "commit": "33a928133fd031b9714cb390645b5b01a900d9f9" }, - "nui.nvim": { "branch": "main", "commit": "b58e2bfda5cea347c9d58b7f11cf3012c7b3953f" }, - "nvim-autopairs": { "branch": "master", "commit": "c15de7e7981f1111642e7e53799e1211d4606cb9" }, - "nvim-bqf": { "branch": "main", "commit": "1b24dc6050c34e8cd377b6b4cd6abe40509e0187" }, - "nvim-cmp": { "branch": "main", "commit": "5260e5e8ecadaf13e6b82cf867a909f54e15fd07" }, - "nvim-colorizer.lua": { "branch": "master", "commit": "0671e0eabc6842676d3310370e8fae4e1c51d7f9" }, - "nvim-dap": { "branch": "master", "commit": "5a2f7121869394502521c52b2bc581ab22c69447" }, - "nvim-dap-ui": { "branch": "master", "commit": "34160a7ce6072ef332f350ae1d4a6a501daf0159" }, - "nvim-dap-virtual-text": { "branch": "master", "commit": "52638640ae309cacdaff785fdbb854437bd1ee5c" }, - "nvim-dap-vscode-js": { "branch": "main", "commit": "03bd29672d7fab5e515fc8469b7d07cc5994bbf6" }, - "nvim-lspconfig": { "branch": "master", "commit": "eadcee1573ca9d0e0cd36a49f620186a8dfdc607" }, - "nvim-nio": { "branch": "master", "commit": "a428f309119086dc78dd4b19306d2d67be884eee" }, - "nvim-notify": { "branch": "master", "commit": "fbef5d32be8466dd76544a257d3f3dce20082a07" }, - "nvim-treesitter": { "branch": "master", "commit": "30de5e7e9486fb1b1b8c2a1e71052b13f94f1cb0" }, - "nvim-ts-autotag": { "branch": "main", "commit": "e239a560f338be31337e7abc3ee42515daf23f5e" }, - "nvim-ts-context-commentstring": { "branch": "main", "commit": "cb064386e667def1d241317deed9fd1b38f0dc2e" }, - "nvim-ufo": { "branch": "main", "commit": "203c9f434feec57909ab4b1e028abeb3349b7847" }, - "nvim-web-devicons": { "branch": "master", "commit": "e37bb1feee9e7320c76050a55443fa843b4b6f83" }, - "onedarker.nvim": { "branch": "freeze", "commit": "b00dd2189f264c5aeb4cf04c59439655ecd573ec" }, - "plenary.nvim": { "branch": "master", "commit": "a3e3bc82a3f95c5ed0d7201546d5d2c19b20d683" }, - "prettier.nvim": { "branch": "main", "commit": "d98e732cb73690b07c00c839c924be1d1d9ac5c2" }, - "project.nvim": { "branch": "main", "commit": "8c6bad7d22eef1b71144b401c9f74ed01526a4fb" }, - "promise-async": { "branch": "main", "commit": "119e8961014c9bfaf1487bf3c2a393d254f337e2" }, - "rust.vim": { "branch": "master", "commit": "889b9a7515db477f4cb6808bef1769e53493c578" }, - "rustaceanvim": { "branch": "master", "commit": "047f9c9d8cd2861745eb9de6c1570ee0875aa795" }, - "schemastore.nvim": { "branch": "main", "commit": "9a5992a881583d886bfbb46631a09f736f0fae50" }, - "structlog.nvim": { "branch": "main", "commit": "45b26a2b1036bb93c0e83f4225e85ab3cee8f476" }, - "tailwind-tools.nvim": { "branch": "master", "commit": "89e560705ecd49607c63c277935c5264bb770d57" }, - "telescope-fzf-native.nvim": { "branch": "main", "commit": "9ef21b2e6bb6ebeaf349a0781745549bbb870d27" }, - "telescope.nvim": { "branch": "0.1.x", "commit": "d829aa64059001ee7b2c8c8aa9c4e6df0b17d893" }, - "toggleterm.nvim": { "branch": "main", "commit": "fee58a0473fd92b28c34f8f724e4918b15ba30a3" }, - "tokyonight.nvim": { "branch": "main", "commit": "b9b494fa7f7bbf2fe0747b47fa290fb7a4eddcc7" }, - "ts-comments.nvim": { "branch": "main", "commit": "98d7d4dec0af1312d38e288f800bbf6ff562b6ab" }, - "typst.vim": { "branch": "main", "commit": "4d18ced62599ffe5b3c0e5e49566d5456121bc02" }, - "vim": { "branch": "legacy", "commit": "99d4b7bf1a0a12f2d78f35a159384b1eb8aa9c15" }, - "vim-illuminate": { "branch": "master", "commit": "5eeb7951fc630682c322e88a9bbdae5c224ff0aa" }, - "vim-react-snippets": { "branch": "main", "commit": "755e288bd0db1052be4195fcc82a25e28b609e0b" }, - "vim-rustfmt": { "branch": "master", "commit": "6bb517be12908926a4f5f516aa510c517c85260e" }, - "vscode-js-debug": { "branch": "main", "commit": "e620efe1841742402a332b532df2aa2ec95361f6" }, - "which-key.nvim": { "branch": "main", "commit": "4433e5ec9a507e5097571ed55c02ea9658fb268a" }, - "winbar.nvim": { "branch": "main", "commit": "13739fdb31be51a1000486189662596f07a59a31" } -} \ No newline at end of file diff --git a/lvim/lua/configs/acmp.lua b/lvim/lua/configs/acmp.lua deleted file mode 100644 index 79e5a54..0000000 --- a/lvim/lua/configs/acmp.lua +++ /dev/null @@ -1,5 +0,0 @@ -require'cmp'.setup { - sources = { - { name = 'nvim_lsp' } - } -} diff --git a/lvim/lua/configs/autocommand.lua b/lvim/lua/configs/autocommand.lua deleted file mode 100644 index 48a1f0f..0000000 --- a/lvim/lua/configs/autocommand.lua +++ /dev/null @@ -1,17 +0,0 @@ --- Autocmds are automatically loaded on the VeryLazy event --- Default autocmds that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/autocmds.lua --- Add any additional autocmds here - -vim.api.nvim_create_autocmd( - { - "BufNewFile", - "BufRead", - }, - { - pattern = "*.typ", - callback = function() - local buf = vim.api.nvim_get_current_buf() - vim.api.nvim_buf_set_option(buf, "filetype", "typst") - end - } -) diff --git a/lvim/lua/configs/autotag.lua b/lvim/lua/configs/autotag.lua deleted file mode 100644 index 92c7ea3..0000000 --- a/lvim/lua/configs/autotag.lua +++ /dev/null @@ -1,8 +0,0 @@ -require('nvim-ts-autotag').setup({ - opts = { - -- Defaults - enable_close = true, -- Auto close tags - enable_rename = true, -- Auto rename pairs of tags - enable_close_on_slash = false -- Auto close on trailing ui', require 'dapui'.toggle) - diff --git a/lvim/lua/configs/dropbar.lua b/lvim/lua/configs/dropbar.lua deleted file mode 100644 index 1e02f5e..0000000 --- a/lvim/lua/configs/dropbar.lua +++ /dev/null @@ -1,37 +0,0 @@ -local sources = require("dropbar.sources") - -local function get_hl_color(group, attr) - return vim.fn.synIDattr(vim.fn.synIDtrans(vim.fn.hlID(group)), attr) -end - -vim.cmd [[hi WinBar guisp=#665c54 guibg=#313131]] -vim.cmd [[hi WinBarNC guisp=#665c54 guibg=#313131]] - -require("dropbar").setup( - { - bar = { - sources = { - { - get_symbols = function(buf, win, cursor) - local symbols = sources.path.get_symbols(buf, win, cursor) - for _, symbol in ipairs(symbols) do - -- get correct icon color - local icon_fg = get_hl_color(symbol.icon_hl, "fg#") - -- symbol.icon_hl = "DropbarSymbol" .. symbol - - local icon_string = "" - -- if icon_fg == "" then - -- icon_string = "hi " .. symbol.icon_hl .. " guisp=#665c54 guibg=#313131" - -- else - -- icon_string = "hi " .. symbol.icon_hl .. " guisp=#665c54 guibg=#313131 guifg=" .. icon_fg - -- end - - vim.cmd(icon_string) - end - return symbols - end - } - } - } - } -) diff --git a/lvim/lua/configs/gitsigns.lua b/lvim/lua/configs/gitsigns.lua deleted file mode 100644 index cad8495..0000000 --- a/lvim/lua/configs/gitsigns.lua +++ /dev/null @@ -1,33 +0,0 @@ -lvim.builtin.gitsigns.opts.signs = { - add = { - hl = "GitSignsAdd", - text = " ┃", - numhl = "GitSignsAddNr", - linehl = "GitSignsAddLn", - }, - change = { - hl = "GitSignsChange", - text = " ┃", - numhl = "GitSignsChangeNr", - linehl = "GitSignsChangeLn", - }, - delete = { - hl = "GitSignsDelete", - text = " ", - numhl = "GitSignsDeleteNr", - linehl = "GitSignsDeleteLn", - }, - topdelete = { - hl = "GitSignsDelete", - text = " ", - numhl = "GitSignsDeleteNr", - linehl = "GitSignsDeleteLn", - }, - changedelete = { - hl = "GitSignsChange", - text = " ┃", - numhl = "GitSignsChangeNr", - linehl = "GitSignsChangeLn", - }, -} - diff --git a/lvim/lua/configs/luasnip.lua b/lvim/lua/configs/luasnip.lua deleted file mode 100644 index 18a6094..0000000 --- a/lvim/lua/configs/luasnip.lua +++ /dev/null @@ -1,22 +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 "" } - -vim.api.nvim_create_autocmd("InsertLeave", { - callback = function() - if - require("luasnip").session.current_nodes[vim.api.nvim_get_current_buf()] - and not require("luasnip").session.jump_active - then - require("luasnip").unlink_current() - end - end, -}) diff --git a/lvim/lua/configs/noice.lua b/lvim/lua/configs/noice.lua deleted file mode 100644 index 805861f..0000000 --- a/lvim/lua/configs/noice.lua +++ /dev/null @@ -1,50 +0,0 @@ -local focused = true - -vim.api.nvim_create_autocmd("FocusGained", { - callback = function() - focused = true - end, -}) -vim.api.nvim_create_autocmd("FocusLost", { - callback = function() - focused = false - end, -}) - - -require("noice").setup({ - table.insert(opts.routes, { - filter = { - event = "notify", - find = "No information available", - }, - opts = { skip = true }, - }), - - table.insert(opts.routes, 1, { - filter = { - cond = function() - return not focused - end, - }, - view = "notify_send", - opts = { stop = false }, - }), - - lsp = { - -- override markdown rendering so that **cmp** and other plugins use **Treesitter** - override = { - ["vim.lsp.util.convert_input_to_markdown_lines"] = true, - ["vim.lsp.util.stylize_markdown"] = true, - ["cmp.entry.get_documentation"] = true, -- requires hrsh7th/nvim-cmp - }, - }, - -- you can enable a preset for easier configuration - presets = { - bottom_search = true, -- use a classic bottom cmdline for search - command_palette = true, -- position the cmdline and popupmenu together - 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/lvim/lua/configs/nvimtree.lua b/lvim/lua/configs/nvimtree.lua deleted file mode 100644 index d7c873f..0000000 --- a/lvim/lua/configs/nvimtree.lua +++ /dev/null @@ -1,63 +0,0 @@ -lvim.builtin.nvimtree.active = false - -vim.fn.sign_define("LspDiagnosticsSignError", - {text = "󰅙 ", texthl = "LspDiagnosticsSignError"}) -vim.fn.sign_define("LspDiagnosticsSignWarning", - {text = "󱇎 ", texthl = "LspDiagnosticsSignWarning"}) -vim.fn.sign_define("LspDiagnosticsSignInformation", - {text = "󰰄 ", texthl = "LspDiagnosticsSignInformation"}) -vim.fn.sign_define("LspDiagnosticsSignHint", - {text = "󰐗 ", texthl = "LspDiagnosticsSignHint"}) - -require("neo-tree").setup({ - close_if_last_window = false, -- Close Neo-tree if it is the last window left in the tab - popup_border_style = "rounded", - enable_git_status = true, - enable_diagnostics = true, - open_files_do_not_replace_types = { "terminal", "trouble", "qf" }, -- when opening files, do not use windows containing these filetypes or buftypes - sort_case_insensitive = false, -- used when sorting files and directories in the tree - sort_function = nil , -- use a custom function for sorting files and directories in the tree - -- sort_function = function (a,b) - -- if a.type == b.type then - -- return a.path > b.path - -- else - -- return a.type > b.type - -- end - -- end , -- this sorts files and directories descendantly - default_component_configs = { - indent = { - with_expanders = true, -- if nil and file nesting is enabled, will enable expanders - }, - icon = { - folder_closed = "󰉋", - folder_open = "󰝰", - folder_empty = "󰉖", - default = "*", - highlight = "NeoTreeFileIcon" - }, - modified = { - symbol = "󰧞", - highlight = "NeoTreeModified", - }, - name = { - trailing_slash = false, - use_git_status_colors = true, - highlight = "NeoTreeFileName", - }, - git_status = { - symbols = { - -- Change type - added = "󰜄", -- or "✚", but this is redundant info if you use git_status_colors on the name - modified = "󰑕", -- or "", but this is redundant info if you use git_status_colors on the name - deleted = "󰅗",-- this can only be used in the git_status source - renamed = "󰛂",-- this can only be used in the git_status source - -- Status type - untracked = "󰞋", - ignored = "󰿠", - unstaged = "󰄱", - staged = "󰄵", - conflict = "", - } - }, - }, -}) diff --git a/lvim/lua/configs/nvimufo.lua b/lvim/lua/configs/nvimufo.lua deleted file mode 100644 index b4b951b..0000000 --- a/lvim/lua/configs/nvimufo.lua +++ /dev/null @@ -1,19 +0,0 @@ -vim.o.foldcolumn = "auto:9" -- '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 -vim.o.fillchars = [[eob: ,fold: ,foldopen:󰅀,foldsep:│,foldclose:󰅂]] - --- 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) - --- Option 3: treesitter as a main provider instead --- (Note: the `nvim-treesitter` plugin is *not* needed.) --- ufo uses the same query files for folding (queries//folds.scm) --- performance and stability are better than `foldmethod=nvim_treesitter#foldexpr()` -require('ufo').setup({ - provider_selector = function(bufnr, filetype, buftype) - return {'treesitter', 'indent'} - end -}) diff --git a/lvim/lua/configs/prettier.lua b/lvim/lua/configs/prettier.lua deleted file mode 100644 index 74aacdb..0000000 --- a/lvim/lua/configs/prettier.lua +++ /dev/null @@ -1,19 +0,0 @@ -local prettier = require("prettier") - -prettier.setup({ - bin = 'prettier', -- or `'prettierd'` (v0.23.3+) - filetypes = { - "css", - "graphql", - "html", - "javascript", - "javascriptreact", - "json", - "less", - "markdown", - "scss", - "typescript", - "typescriptreact", - "yaml", - }, -}) diff --git a/lvim/lua/mappings.lua b/lvim/lua/mappings.lua deleted file mode 100644 index 3295c5e..0000000 --- a/lvim/lua/mappings.lua +++ /dev/null @@ -1,56 +0,0 @@ -local map = vim.keymap.set - -map("n", ";", ":", { desc = "CMD enter command mode" }) - -map("i", "", "", { desc = "move left" }) -map("i", "", "", { desc = "move right" }) -map("i", "", "", { desc = "move down" }) -map("i", "", "", { desc = "move up" }) - -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" }) - -map("n", "", "NeoTreeShowToggle", { desc = "nvimtree toggle window" }) - -map("n", "", "BufferLineMoveNext", { desc = "move buffer to right" }) -map("n", "", "BufferLineMovePrev", { desc = "move buffer to left" }) -map("n", "", "BufferLineCycleNext", { desc = "switch to next buffer" }) -map("n", "", "BufferLineCyclePrev", { desc = "switch to prev buffer" }) - -lvim.builtin.which_key.mappings["ln"] = { "set norelativenumber", "Toggle line number" } -lvim.builtin.which_key.mappings["e"] = { "NeoTreeFocus", "Nvimtree focus window" } -lvim.builtin.which_key.mappings["rn"] = { "set relativenumber", "Toggle relative number" } -lvim.builtin.which_key.mappings["ns"] = { "split", "Horizontal split" } -lvim.builtin.which_key.mappings["vs"] = { "vsplit", "Vertical split" } - -map("n", "", "DapContinue") -map("n", "", "DapToggleBreakpoint") - -map("n", "mk", "RustLsp moveItem up") -map("n", "m,", "RustLsp moveItem down") -map("n", "rs", "RustLsp run") -map("n", "hh", "RustLsp hover actions") -map("n", "ca", "RustLsp codeAction") -map("n", "", "w!") -map("i", "", "w!") - -map("n", "dr", " DapContinue ", { desc = "Continue debug" } ) - -map("n", "do", function() - require("dapui").open() -end, { desc = "Open DAP ui" }) -map("n", "dc", function() - require("dapui").close() -end, { desc = "Start or continue debug" }) -map("n", "dt", function() - require("dapui").toggle() -end, { desc = "Toggle DAP ui" }) - -map("n", "+", "vertical resize +5", { desc = "Increase vertical buffer" }) -- make the window biger vertically -map("n", "-", "vertical resize -5", { desc = "Decrease vertical buffer" }) -- make the window smaller vertically -map("n", "=", "horizontal resize -2", { desc = "Decrease horizontal buffer" }) -- make the window smaller horizontally by pressing shift and - -map("n", "_", "horizontal resize +2", { desc = "Increase horizontal buffer" }) -- make the window bigger horizontally by pressing shift and = -map("n", "", "foldopen") -map("n", "", "foldclose") diff --git a/lvim/lua/plugins/init.lua b/lvim/lua/plugins/init.lua deleted file mode 100644 index 9cbd525..0000000 --- a/lvim/lua/plugins/init.lua +++ /dev/null @@ -1,278 +0,0 @@ -lvim.plugins = { - { - "williamboman/mason.nvim", - opts = { - ensure_installed = { - "eslint-lsp", - "js-debug-adapter", - "prettier", - "tinymist", - "typescript-language-server", - } - } - }, - { - "kaarmu/typst.vim", - }, - { - "neovim/nvim-lspconfig", - dependencies = { - "mason.nvim", - "williamboman/mason-lspconfig.nvim", - }, - }, - { - 'kevinhwang91/nvim-ufo', - opts = { - open_fold_hl_timeout = 400, - close_fold_kinds = { "imports", "comment" }, - preview = { - win_config = { - border = { "", "─", "", "", "", "─", "", "" }, - -- winhighlight = "Normal:Folded", - winblend = 0, - }, - mappings = { - scrollU = "", - scrollD = "", - jumpTop = "[", - jumpBot = "]", - }, - }, - }, - config = function(_, opts) - local handler = function(virtText, lnum, endLnum, width, truncate) - local newVirtText = {} - local totalLines = vim.api.nvim_buf_line_count(0) - local foldedLines = endLnum - lnum - local suffix = ("  %d %d%%"):format(foldedLines, foldedLines / totalLines * 100) - local sufWidth = vim.fn.strdisplaywidth(suffix) - local targetWidth = width - sufWidth - local curWidth = 0 - for _, chunk in ipairs(virtText) do - local chunkText = chunk[1] - local chunkWidth = vim.fn.strdisplaywidth(chunkText) - if targetWidth > curWidth + chunkWidth then - table.insert(newVirtText, chunk) - else - chunkText = truncate(chunkText, targetWidth - curWidth) - local hlGroup = chunk[2] - table.insert(newVirtText, { chunkText, hlGroup }) - chunkWidth = vim.fn.strdisplaywidth(chunkText) - -- str width returned from truncate() may less than 2nd argument, need padding - if curWidth + chunkWidth < targetWidth then - suffix = suffix .. (" "):rep(targetWidth - curWidth - chunkWidth) - end - break - end - curWidth = curWidth + chunkWidth - end - local rAlignAppndx = - math.max(math.min(vim.opt.textwidth["_value"], width - 1) - curWidth - sufWidth, 0) - suffix = (" "):rep(rAlignAppndx) .. suffix - table.insert(newVirtText, { suffix, "MoreMsg" }) - return newVirtText - end - opts["fold_virt_text_handler"] = handler - require("ufo").setup(opts) - vim.keymap.set("n", "K", function() - local winid = require("ufo").peekFoldedLinesUnderCursor() - if not winid then - -- vim.lsp.buf.hover() - vim.cmd [[ Lspsaga hover_doc ]] - end - end) - end, - }, - { - 'kevinhwang91/promise-async', - }, - { - 'rust-lang/rust.vim', - }, - { - 'MunifTanjim/prettier.nvim' - }, - { - 'alx741/vim-rustfmt', - }, - { - "savq/melange-nvim" - }, - { - 'theHamsta/nvim-dap-virtual-text', - }, - { - "HoNamDuong/hybrid.nvim", - lazy = false, - priority = 1000, - opts = {}, - }, - { - 'marko-cerovac/material.nvim' - }, - { - "rebelot/kanagawa.nvim", - }, - { - 'mountain-theme/vim' - }, - { - 'fgheng/winbar.nvim' - }, - { - "gbprod/nord.nvim", - }, - { - "vague2k/huez.nvim", - }, - { - "Bekaboo/dropbar.nvim", - dependencies = { - "nvim-telescope/telescope-fzf-native.nvim" - }, - }, - { - "nvim-neo-tree/neo-tree.nvim", - branch = "v2.x", - dependencies = { - "nvim-lua/plenary.nvim", - "nvim-tree/nvim-web-devicons", - "MunifTanjim/nui.nvim", - }, - }, - -- load luasnips + cmp related in insert mode only - { - "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, - }, - { - "saadparwaiz1/cmp_luasnip", - "hrsh7th/cmp-nvim-lua", - "hrsh7th/cmp-nvim-lsp", - "hrsh7th/cmp-buffer", - "hrsh7th/cmp-path", - }, - }, - }, - { - "hrsh7th/cmp-nvim-lsp", - }, - { - "luckasRanarison/tailwind-tools.nvim", - dependencies = { "nvim-treesitter/nvim-treesitter" }, - }, - { - "kyazdani42/nvim-web-devicons" - }, - { - "mfussenegger/nvim-dap", - event = "VeryLazy", - }, - { - "rcarriga/nvim-dap-ui", - dependencies = { - "nvim-neotest/nvim-nio", - "mfussenegger/nvim-dap", - }, - event = "VeryLazy", - config = function() - require("dapui").setup() - end - }, - { - "mxsdev/nvim-dap-vscode-js" - }, - { - "microsoft/vscode-js-debug", - lazy = true, - build = "npm install --legacy-peer-deps && npx gulp vsDebugServerBundle && mv dist out" - }, - { - 'NvChad/nvim-colorizer.lua', - }, - { - "folke/neodev.nvim", opts = {} - }, - { - "mlaursen/vim-react-snippets", - }, - { - "windwp/nvim-ts-autotag", - }, - { - "folke/ts-comments.nvim", - event = "VeryLazy", - enabled = vim.fn.has("nvim-0.10.0") == 1, - }, - { - "windwp/nvim-autopairs", - event = "InsertEnter", - config = true - -- use opts = {} for passing setup options - -- this is equalent to setup({}) function - }, - { - "nvim-treesitter/nvim-treesitter", - }, - { - "mrcjkb/rustaceanvim", - version = '^4', -- Recommended - lazy = false, -- This plugin is already lazy - }, - { - "NeogitOrg/neogit", - dependencies = { - "nvim-lua/plenary.nvim", -- required - "sindrets/diffview.nvim", -- optional - Diff integration - - -- Only one of these is needed, not both. - "nvim-telescope/telescope.nvim", -- optional - "ibhagwan/fzf-lua", -- optional - }, - config = true, - }, - { - "catppuccin/nvim", - name = "catppuccin", - priority = 1000 - }, - { - "loctvl842/monokai-pro.nvim" - }, - { - "tanvirtin/monokai.nvim" - }, - { - "folke/noice.nvim", - event = "VeryLazy", - opts = { - routes = { - { - filter = { event = "notify", find = "No information available" }, - opts = { skip = true }, - }, - }, - presets = { - lsp_doc_border = true, - }, - }, - dependencies = { - -- if you lazy-load any plugin below, make sure to add proper `module="..."` entries - "MunifTanjim/nui.nvim", - -- OPTIONAL: - -- `nvim-notify` is only needed, if you want to use the notification view. - -- If not available, we use `mini` as the fallback - } - }, -} -