From e62c2c3c95855232f0211459966a45a098f46a43 Mon Sep 17 00:00:00 2001 From: Christian Segundo Date: Sat, 20 Jan 2024 23:56:23 +0100 Subject: mass exodus --- .../nvim/.nvim/lua/plugins/core/auto-session.lua | 6 --- public/nvim/.nvim/lua/plugins/core/gitsigns.lua | 8 ---- public/nvim/.nvim/lua/plugins/core/luasnip.lua | 50 -------------------- .../nvim/.nvim/lua/plugins/core/nerdcommenter.lua | 18 -------- public/nvim/.nvim/lua/plugins/core/nvim-tree.lua | 36 --------------- public/nvim/.nvim/lua/plugins/core/tabline.lua | 3 -- public/nvim/.nvim/lua/plugins/core/telescope.lua | 27 ----------- public/nvim/.nvim/lua/plugins/core/tmux.lua | 13 ------ public/nvim/.nvim/lua/plugins/core/treesitter.lua | 54 ---------------------- public/nvim/.nvim/lua/plugins/core/which-key.lua | 45 ------------------ 10 files changed, 260 deletions(-) delete mode 100644 public/nvim/.nvim/lua/plugins/core/auto-session.lua delete mode 100644 public/nvim/.nvim/lua/plugins/core/gitsigns.lua delete mode 100644 public/nvim/.nvim/lua/plugins/core/luasnip.lua delete mode 100644 public/nvim/.nvim/lua/plugins/core/nerdcommenter.lua delete mode 100644 public/nvim/.nvim/lua/plugins/core/nvim-tree.lua delete mode 100644 public/nvim/.nvim/lua/plugins/core/tabline.lua delete mode 100644 public/nvim/.nvim/lua/plugins/core/telescope.lua delete mode 100644 public/nvim/.nvim/lua/plugins/core/tmux.lua delete mode 100644 public/nvim/.nvim/lua/plugins/core/treesitter.lua delete mode 100644 public/nvim/.nvim/lua/plugins/core/which-key.lua (limited to 'public/nvim/.nvim/lua/plugins/core') diff --git a/public/nvim/.nvim/lua/plugins/core/auto-session.lua b/public/nvim/.nvim/lua/plugins/core/auto-session.lua deleted file mode 100644 index 9bfcac0..0000000 --- a/public/nvim/.nvim/lua/plugins/core/auto-session.lua +++ /dev/null @@ -1,6 +0,0 @@ -return { - "rmagatti/auto-session", - config = function() - require("auto-session").setup({ log_level = "info" }) - end, -} diff --git a/public/nvim/.nvim/lua/plugins/core/gitsigns.lua b/public/nvim/.nvim/lua/plugins/core/gitsigns.lua deleted file mode 100644 index e856855..0000000 --- a/public/nvim/.nvim/lua/plugins/core/gitsigns.lua +++ /dev/null @@ -1,8 +0,0 @@ -return { - "lewis6991/gitsigns.nvim", - event = { "BufRead" }, - config = function() - require("gitsigns").setup() - end, - dependencies = { "nvim-lua/plenary.nvim" }, -} diff --git a/public/nvim/.nvim/lua/plugins/core/luasnip.lua b/public/nvim/.nvim/lua/plugins/core/luasnip.lua deleted file mode 100644 index 622af58..0000000 --- a/public/nvim/.nvim/lua/plugins/core/luasnip.lua +++ /dev/null @@ -1,50 +0,0 @@ -return { - { - "L3MON4D3/LuaSnip", - dependencies = { "rafamadriz/friendly-snippets" }, - build = "make install_jsregexp", - config = function() - local ls = require("luasnip") - local types = require("luasnip.util.types") - - ls.config.set_config({ - history = true, - updateevents = "TextChanged,TextChangedI", - enable_autosnippets = true, - ext_opts = { - [types.choiceNode] = { - active = { - virt_text = { { "<-", "Error" } }, - }, - }, - }, - }) - - -- luasnip keymaps are defined as cmp keymaps - - vim.keymap.set( - "n", - "s", - 'lua require("luasnip.loaders.from_lua").load({ paths = "~/.config/nvim/lua/snippets" })' - ) - - require("luasnip.loaders.from_lua").lazy_load({ paths = "~/.config/nvim/lua/snippets" }) - end, - }, - - -- VSCode like (JSON) snippets - -- For the full list of supported languages see: - -- https://github.com/rafamadriz/friendly-snippets/blob/main/package.json - { - "rafamadriz/friendly-snippets", - opts = { include = {} }, - config = function(_, opts) - if #opts.include == 0 then - return - end - - opts.path = "~/.local/share/nvim/lazy/friendly-snippets" - require("luasnip.loaders.from_vscode").lazy_load(opts) - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/core/nerdcommenter.lua b/public/nvim/.nvim/lua/plugins/core/nerdcommenter.lua deleted file mode 100644 index 720b3d2..0000000 --- a/public/nvim/.nvim/lua/plugins/core/nerdcommenter.lua +++ /dev/null @@ -1,18 +0,0 @@ -return { - "preservim/nerdcommenter", - init = function() - vim.g.NERDCreateDefaultMappings = 0 - end, - config = function() - vim.api.nvim_set_keymap("v", "cc", "NERDCommenterComment", { silent = true }) - vim.api.nvim_set_keymap("v", "cu", "NERDCommenterUncomment", { silent = true }) - vim.api.nvim_set_keymap("n", "cc", "NERDCommenterComment", { noremap = false, silent = true }) - vim.api.nvim_set_keymap("n", "cu", "NERDCommenterUncomment", { noremap = false, silent = true }) - end, - keys = { - { "cc", mode = "v" }, - { "cc", mode = "n" }, - { "cu", mode = "v" }, - { "cu", mode = "n" }, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/core/nvim-tree.lua b/public/nvim/.nvim/lua/plugins/core/nvim-tree.lua deleted file mode 100644 index e8ca82f..0000000 --- a/public/nvim/.nvim/lua/plugins/core/nvim-tree.lua +++ /dev/null @@ -1,36 +0,0 @@ -return { - { - "nvim-tree/nvim-tree.lua", - config = function() - require("nvim-tree").setup({ - sync_root_with_cwd = false, - update_focused_file = { - enable = true, - update_root = false, - }, - renderer = { - indent_markers = { enable = true }, - highlight_git = true, - highlight_opened_files = "all", - }, - }) - end, - dependencies = { "nvim-tree/nvim-web-devicons" }, - }, - - -- Add nvim-tree which-key shortcuts - { - "folke/which-key.nvim", - opts = function(_, opts) - if type(opts) ~= "table" then - opts = {} - end - - if type(opts.f) ~= "table" then - opts["f"] = {} - end - - opts.f["e"] = { "NvimTreeToggle", "Explorer" } - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/core/tabline.lua b/public/nvim/.nvim/lua/plugins/core/tabline.lua deleted file mode 100644 index 0a8305d..0000000 --- a/public/nvim/.nvim/lua/plugins/core/tabline.lua +++ /dev/null @@ -1,3 +0,0 @@ -return { - "mkitt/tabline.vim", -} diff --git a/public/nvim/.nvim/lua/plugins/core/telescope.lua b/public/nvim/.nvim/lua/plugins/core/telescope.lua deleted file mode 100644 index 367e20c..0000000 --- a/public/nvim/.nvim/lua/plugins/core/telescope.lua +++ /dev/null @@ -1,27 +0,0 @@ -return { - { - "nvim-telescope/telescope.nvim", - config = function() - require("telescope").load_extension("file_browser") - end, - dependencies = { - "nvim-lua/plenary.nvim", - "nvim-telescope/telescope-file-browser.nvim", - }, - }, - - { - "folke/which-key.nvim", - opts = function(_, opts) - if type(opts) == "table" then - opts.b = opts.b or {} - opts.f = opts.f or {} - - opts.b["b"] = { "Telescope buffers", "All" } - opts.f["f"] = { "Telescope find_files", "Find" } - opts.f["g"] = { "Telescope live_grep", "Grep" } - opts.f["b"] = { "Telescope file_browser", "Browse" } - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/core/tmux.lua b/public/nvim/.nvim/lua/plugins/core/tmux.lua deleted file mode 100644 index 0d63aa4..0000000 --- a/public/nvim/.nvim/lua/plugins/core/tmux.lua +++ /dev/null @@ -1,13 +0,0 @@ -return { - "christoomey/vim-tmux-navigator", - config = function() - local nvim_set_keymap = vim.api.nvim_set_keymap - vim.g.tmux_navigator_no_mappings = 1 - for _, mode in pairs({ "n", "v", "i", "t" }) do - nvim_set_keymap(mode, "", ":TmuxNavigateDown", { noremap = true }) - nvim_set_keymap(mode, "", ":TmuxNavigateUp", { noremap = true }) - nvim_set_keymap(mode, "", ":TmuxNavigateLeft", { noremap = true }) - nvim_set_keymap(mode, "", ":TmuxNavigateRight", { noremap = true }) - end - end, -} diff --git a/public/nvim/.nvim/lua/plugins/core/treesitter.lua b/public/nvim/.nvim/lua/plugins/core/treesitter.lua deleted file mode 100644 index 3818555..0000000 --- a/public/nvim/.nvim/lua/plugins/core/treesitter.lua +++ /dev/null @@ -1,54 +0,0 @@ ----@param tbl table ----@return table -local tbl_uniq = function(tbl) - ---@type table - local added = {} - local res = {} - res = vim.tbl_filter(function(k) - if added[k] then - return false - end - added[k] = true - return true - end, tbl) - - return res -end - -return { - { - "nvim-treesitter/nvim-treesitter", - build = ":TSUpdate", - cmd = { "TSUpdateSync" }, - event = { "BufReadPost", "BufNewFile" }, - init = function() - vim.o.foldmethod = "expr" - vim.o.foldexpr = "nvim_treesitter#foldexpr()" - end, - opts = { - ensure_installed = { "query" }, - ignore_install = {}, - highlight = { - enable = true, - }, - query_linter = { - enable = true, - use_virtual_text = true, - lint_events = { "BufWrite", "CursorHold" }, - }, - }, - config = function(_, opts) - if type(opts.ensure_installed) == "table" then - opts.ensure_installed = tbl_uniq(opts.ensure_installed) - end - require("nvim-treesitter.configs").setup(opts) - end, - }, - - { - "nvim-treesitter/playground", - build = ":TSInstall query", - dependencies = { "nvim-treesitter" }, - cmd = { "TSPlaygroundToggle" }, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/core/which-key.lua b/public/nvim/.nvim/lua/plugins/core/which-key.lua deleted file mode 100644 index 6e046a3..0000000 --- a/public/nvim/.nvim/lua/plugins/core/which-key.lua +++ /dev/null @@ -1,45 +0,0 @@ -return { - "folke/which-key.nvim", - event = "VeryLazy", - init = function() - vim.o.timeout = true - vim.o.timeoutlen = 300 - end, - - opts = { - f = { name = "File" }, - b = { - name = "Buffer", - n = { "BufferNext", "Next" }, - p = { "BufferPrevious", "Previous" }, - c = { "BufferClose", "Close" }, - ["1"] = { "BufferGoto 1", "1" }, - ["2"] = { "BufferGoto 2", "2" }, - ["3"] = { "BufferGoto 3", "3" }, - ["4"] = { "BufferGoto 4", "4" }, - ["5"] = { "BufferGoto 5", "5" }, - ["6"] = { "BufferGoto 6", "6" }, - ["7"] = { "BufferGoto 7", "7" }, - ["8"] = { "BufferGoto 8", "8" }, - ["9"] = { "BufferGoto 9", "9" }, - }, - l = { - name = "LSP", - a = { "lua vim.lsp.buf.code_action()", "Action" }, - f = { "lua vim.lsp.buf.format({ async = false, timeout_ms = 5000 })", "Format" }, - d = { "lua vim.diagnostic.open_float()", "Diagnostic" }, - h = { "lua vim.lsp.buf.hover()", "Help" }, - g = { - name = "Go to", - D = { "lua vim.lsp.buf.declaration()", "Go to declaration" }, - d = { "lua vim.lsp.buf.definition()", "Go to definition" }, - i = { "lua vim.lsp.buf.definition()", "Go to implementation" }, - }, - }, - }, - - config = function(_, opts) - local wk = require("which-key") - wk.register(opts, { prefix = "" }) - end, -} -- cgit v1.2.3