From e62c2c3c95855232f0211459966a45a098f46a43 Mon Sep 17 00:00:00 2001 From: Christian Segundo Date: Sat, 20 Jan 2024 23:56:23 +0100 Subject: mass exodus --- public/nvim/.nvim/lua/core/disable_builtin.lua | 16 ---- public/nvim/.nvim/lua/core/init.lua | 64 -------------- .../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 ---------- public/nvim/.nvim/lua/plugins/extra/copilot.lua | 33 -------- public/nvim/.nvim/lua/plugins/extra/feline.lua | 84 ------------------- .../nvim/.nvim/lua/plugins/extra/vim-fugitive.lua | 14 ---- .../lua/plugins/eyecandy/indent-blankline.lua | 22 ----- public/nvim/.nvim/lua/plugins/eyecandy/themes.lua | 25 ------ .../.nvim/lua/plugins/eyecandy/vim-illuminate.lua | 4 - .../.nvim/lua/plugins/eyecandy/virt-column.lua | 7 -- public/nvim/.nvim/lua/plugins/lang/ansible.lua | 21 ----- public/nvim/.nvim/lua/plugins/lang/bash.lua | 41 --------- public/nvim/.nvim/lua/plugins/lang/c.lua | 20 ----- public/nvim/.nvim/lua/plugins/lang/dockerfile.lua | 24 ------ public/nvim/.nvim/lua/plugins/lang/go.lua | 65 --------------- public/nvim/.nvim/lua/plugins/lang/groovy.lua | 38 --------- public/nvim/.nvim/lua/plugins/lang/helm.lua | 6 -- public/nvim/.nvim/lua/plugins/lang/jq.lua | 21 ----- public/nvim/.nvim/lua/plugins/lang/json.lua | 21 ----- public/nvim/.nvim/lua/plugins/lang/jsonnet.lua | 26 ------ public/nvim/.nvim/lua/plugins/lang/ledger.lua | 25 ------ public/nvim/.nvim/lua/plugins/lang/lua.lua | 46 ---------- public/nvim/.nvim/lua/plugins/lang/markdown.lua | 76 ----------------- public/nvim/.nvim/lua/plugins/lang/perl.lua | 36 -------- public/nvim/.nvim/lua/plugins/lang/promql.lua | 19 ----- public/nvim/.nvim/lua/plugins/lang/swift.lua | 35 -------- public/nvim/.nvim/lua/plugins/lang/terraform.lua | 40 --------- public/nvim/.nvim/lua/plugins/lang/typescript.lua | 34 -------- public/nvim/.nvim/lua/plugins/lang/yaml.lua | 59 ------------- public/nvim/.nvim/lua/plugins/lang/zig.lua | 40 --------- public/nvim/.nvim/lua/plugins/lsp/cmp.lua | 97 ---------------------- public/nvim/.nvim/lua/plugins/lsp/config.lua | 45 ---------- public/nvim/.nvim/lua/plugins/lsp/null-ls.lua | 5 -- public/nvim/.nvim/lua/plugins/lsp/trouble.lua | 9 -- public/nvim/.nvim/lua/snippets/lua.lua | 3 - public/nvim/.nvim/lua/snippets/sh/bash-find.lua | 32 ------- public/nvim/.nvim/lua/snippets/sh/bash-misc.lua | 16 ---- 46 files changed, 1429 deletions(-) delete mode 100644 public/nvim/.nvim/lua/core/disable_builtin.lua delete mode 100644 public/nvim/.nvim/lua/core/init.lua 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 delete mode 100644 public/nvim/.nvim/lua/plugins/extra/copilot.lua delete mode 100644 public/nvim/.nvim/lua/plugins/extra/feline.lua delete mode 100644 public/nvim/.nvim/lua/plugins/extra/vim-fugitive.lua delete mode 100644 public/nvim/.nvim/lua/plugins/eyecandy/indent-blankline.lua delete mode 100644 public/nvim/.nvim/lua/plugins/eyecandy/themes.lua delete mode 100644 public/nvim/.nvim/lua/plugins/eyecandy/vim-illuminate.lua delete mode 100644 public/nvim/.nvim/lua/plugins/eyecandy/virt-column.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/ansible.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/bash.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/c.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/dockerfile.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/go.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/groovy.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/helm.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/jq.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/json.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/jsonnet.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/ledger.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/lua.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/markdown.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/perl.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/promql.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/swift.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/terraform.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/typescript.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/yaml.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lang/zig.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lsp/cmp.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lsp/config.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lsp/null-ls.lua delete mode 100644 public/nvim/.nvim/lua/plugins/lsp/trouble.lua delete mode 100644 public/nvim/.nvim/lua/snippets/lua.lua delete mode 100644 public/nvim/.nvim/lua/snippets/sh/bash-find.lua delete mode 100644 public/nvim/.nvim/lua/snippets/sh/bash-misc.lua (limited to 'public/nvim/.nvim/lua') diff --git a/public/nvim/.nvim/lua/core/disable_builtin.lua b/public/nvim/.nvim/lua/core/disable_builtin.lua deleted file mode 100644 index ea546ba..0000000 --- a/public/nvim/.nvim/lua/core/disable_builtin.lua +++ /dev/null @@ -1,16 +0,0 @@ -vim.g.loaded_gzip = 1 -vim.g.loaded_zip = 1 -vim.g.loaded_zipPlugin = 1 -vim.g.loaded_tar = 1 -vim.g.loaded_tarPlugin = 1 - -vim.g.loaded_getscript = 1 -vim.g.loaded_getscriptPlugin = 1 -vim.g.loaded_vimball = 1 -vim.g.loaded_vimballPlugin = 1 -vim.g.loaded_2html_plugin = 1 - -vim.g.loaded_matchit = 1 -vim.g.loaded_matchparen = 1 -vim.g.loaded_logiPat = 1 -vim.g.loaded_rrhelper = 1 diff --git a/public/nvim/.nvim/lua/core/init.lua b/public/nvim/.nvim/lua/core/init.lua deleted file mode 100644 index 3c34282..0000000 --- a/public/nvim/.nvim/lua/core/init.lua +++ /dev/null @@ -1,64 +0,0 @@ ------------------------------------------------------------ --- General ------------------------------------------------------------ -vim.opt.mouse = "a" -- Enable mouse support -vim.opt.clipboard = "unnamedplus" -- Copy/paste to system clipboard -vim.opt.termguicolors = true -- Enable 24-bit RGB colors -vim.o.background = "light" -vim.opt.hidden = true -vim.opt.number = true -vim.o.cursorlineopt = "both" -vim.opt.conceallevel = 0 -vim.opt.relativenumber = true -vim.opt.showcmd = true -vim.opt.showmode = true -vim.opt.colorcolumn = "80" -vim.opt.cursorline = true -vim.opt.foldlevelstart = 99 -vim.opt.showtabline = 1 -vim.opt.laststatus = 3 -- Single status line across all buffers -vim.opt.undofile = true -vim.opt.list = true -- Show some invisible characters like tabs -vim.opt.undodir = vim.fn.stdpath("config") .. "/undo" -vim.o.sessionoptions = "blank,buffers,curdir,folds,help,tabpages,winsize,winpos,terminal" --- TODO make it pretty with the highlights ---vim.opt.winbar = '%!luaeval("_winbar()")' -- The winbar text, I don't know if it is possible to embed it directly here :( ---vim.opt.winbar = "%=%m %t%=" ------------------------------------------------------------ --- Tabs, indent ------------------------------------------------------------ -vim.opt.expandtab = true -- Use spaces instead of tabs -vim.opt.shiftwidth = 2 -- Shift 4 spaces when tab -vim.opt.tabstop = 2 -- 1 tab == 4 spaces -vim.opt.smartindent = true -- Autoindent new lines - ------------------------------------------------------------ --- Custom keymaps ------------------------------------------------------------ -vim.api.nvim_set_keymap("i", "jk", "", {}) -- Use jk to exit insert mode -vim.api.nvim_set_keymap("i", "kj", "", {}) -- Use kj to exit insert mode -vim.api.nvim_set_keymap("t", "jk", "", {}) -- Use jk to exit terminal mode -vim.api.nvim_set_keymap("t", "kj", "", {}) -- Use kj to exit terminal mode -vim.api.nvim_set_keymap("t", "", "", { noremap = true }) -- Use Esc to exit terminal mode - -vim.api.nvim_set_keymap("i", "", ":tabnew", {}) -- New tab -vim.api.nvim_set_keymap("n", "", ":tabnew", {}) -- New tab - --- No arrow keys for movement ---nnoremap ---nnoremap ---inoremap ---inoremap ---inoremap ---inoremap - ---Left and right to switch buffers ---nnoremap :bp ---nnoremap :bn - ---_winbar = function() -- My custom winbar text ---local filename = vim.fn.expand('%') ---return string.gsub(filename, 'term://.*:', '') ---end - -require("core.disable_builtin") 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, -} diff --git a/public/nvim/.nvim/lua/plugins/extra/copilot.lua b/public/nvim/.nvim/lua/plugins/extra/copilot.lua deleted file mode 100644 index 15d0c73..0000000 --- a/public/nvim/.nvim/lua/plugins/extra/copilot.lua +++ /dev/null @@ -1,33 +0,0 @@ -return { - { - "zbirenbaum/copilot.lua", - event = { "InsertEnter" }, - build = ":Copilot auth", - config = function() - vim.schedule(function() - require("copilot").setup({ - filetypes = { yaml = true }, - suggestion = { enabled = false }, - panel = { enabled = false }, - }) - end) - end, - }, - - { - "zbirenbaum/copilot-cmp", - dependencies = { "copilot.lua" }, - opts = {}, - }, - - { - "hrsh7th/nvim-cmp", - dependencies = { "zbirenbaum/copilot-cmp" }, - opts = function(_, opts) - if type(opts) == "table" then - table.insert(opts.sources, 1, { name = "copilot" }) - opts.formatting.format.menu["copilot"] = "" - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/extra/feline.lua b/public/nvim/.nvim/lua/plugins/extra/feline.lua deleted file mode 100644 index 037db34..0000000 --- a/public/nvim/.nvim/lua/plugins/extra/feline.lua +++ /dev/null @@ -1,84 +0,0 @@ -return { - { - "feline-nvim/feline.nvim", - dependencies = { "nvim-navic", "catppuccin", "nvim-tree/nvim-web-devicons" }, - config = function() - local ctp_feline = require("catppuccin.groups.integrations.feline") - ctp_feline.setup({ - assets = { - left_separator = "", - right_separator = "", - }, - }) - - local catpuccin_components = ctp_feline.get() - require("feline").setup({ components = catpuccin_components }) - - local catpuccin_winbar_components = { active = { {}, {}, {} }, inactive = {} } - --catpuccin_winbar_components.inactive = catpuccin_components.inactive - - -- Removes the mode_icon and its left padding - --table.remove(catpuccin_components.active[1], 2) - --table.remove(catpuccin_components.active[1], 1) - --local catpuccin_winbar_components = catpuccin_components - - --local yaml_schema_component = { - --provider = function() - --local schema = require("yaml-companion").get_buf_schema(0) - --return schema.result[1].name - --end, - --enabled = function() - --local enabled = catpuccin_components.active[3][1].enabled - --if vim.bo.filetype == "yaml" and enabled then - --return true - --end - --end, - --hl = catpuccin_components.active[3][1].hl, - --left_sep = catpuccin_components.active[3][1].left_sep, - --right_sep = catpuccin_components.active[3][1].right_sep, - --} - - local navic_component = { - provider = function() - local location = require("nvim-navic").get_location() - if location == "" then - return location - end - return "> " .. require("nvim-navic").get_location() - end, - enabled = function() - local ok, navic = pcall(require, "nvim-navic") - if ok then - return navic.is_available() - end - end, - hl = { - bg = require("catppuccin.palettes").get_palette().base, - fg = catpuccin_components.active[3][1].hl.fg, - }, - } - - --table.insert(catpuccin_components.active[3], 1, yaml_schema_component) - -- Overwrite the useless LSP component - --catpuccin_components.active[3][2] = yaml_schema_component - - -- this is a hack to properly align the next component - catpuccin_winbar_components.active[1][1] = { - provider = function() - return " " - end, - hl = { - bg = require("catppuccin.palettes").get_palette().base, - fg = require("catppuccin.palettes").get_palette().base, - }, - } - - catpuccin_winbar_components.active[1][2] = navic_component - catpuccin_winbar_components.inactive = catpuccin_winbar_components.active - - require("feline").winbar.setup({ - components = catpuccin_winbar_components, - }) - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/extra/vim-fugitive.lua b/public/nvim/.nvim/lua/plugins/extra/vim-fugitive.lua deleted file mode 100644 index d1f8a5a..0000000 --- a/public/nvim/.nvim/lua/plugins/extra/vim-fugitive.lua +++ /dev/null @@ -1,14 +0,0 @@ -return { - { - "shumphrey/fugitive-gitlab.vim", - cmd = "GBrowse", - config = function() - vim.g.fugitive_gitlab_domains = { "https://gitlab.otters.xyz" } - end, - }, - - { - "tpope/vim-fugitive", - dependencies = { "tpope/vim-rhubarb", "fugitive-gitlab.vim" }, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/eyecandy/indent-blankline.lua b/public/nvim/.nvim/lua/plugins/eyecandy/indent-blankline.lua deleted file mode 100644 index 8756757..0000000 --- a/public/nvim/.nvim/lua/plugins/eyecandy/indent-blankline.lua +++ /dev/null @@ -1,22 +0,0 @@ -return { - "lukas-reineke/indent-blankline.nvim", - event = { "BufRead" }, - main = "ibl", - opts = { - indent = { - char = "▏", - tab_char = "▏", - }, - scope = { - enabled = true, - show_start = true, - show_end = true, - exclude = { - language = { - "help", - }, - }, - }, - }, - dependencies = { "nvim-treesitter" }, -} diff --git a/public/nvim/.nvim/lua/plugins/eyecandy/themes.lua b/public/nvim/.nvim/lua/plugins/eyecandy/themes.lua deleted file mode 100644 index 42e5d6c..0000000 --- a/public/nvim/.nvim/lua/plugins/eyecandy/themes.lua +++ /dev/null @@ -1,25 +0,0 @@ -return { - { - "catppuccin/nvim", - lazy = false, - priority = 1000, - name = "catppuccin", - config = function() - local catp = require("catppuccin") - catp.setup({ - flavour = "frappe", - integrations = { - indent_blankline = true, - which_key = true, - illuminate = true, - lsp_trouble = true, - navic = { - enabled = true, - custom_bg = "NONE", - }, - }, - }) - vim.api.nvim_command("colorscheme catppuccin") - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/eyecandy/vim-illuminate.lua b/public/nvim/.nvim/lua/plugins/eyecandy/vim-illuminate.lua deleted file mode 100644 index 20b9bb2..0000000 --- a/public/nvim/.nvim/lua/plugins/eyecandy/vim-illuminate.lua +++ /dev/null @@ -1,4 +0,0 @@ -return { - "RRethy/vim-illuminate", - event = { "BufRead" }, -} diff --git a/public/nvim/.nvim/lua/plugins/eyecandy/virt-column.lua b/public/nvim/.nvim/lua/plugins/eyecandy/virt-column.lua deleted file mode 100644 index 5259d7a..0000000 --- a/public/nvim/.nvim/lua/plugins/eyecandy/virt-column.lua +++ /dev/null @@ -1,7 +0,0 @@ -return { - "lukas-reineke/virt-column.nvim", - event = { "BufRead" }, - config = function() - require("virt-column").setup() - end, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/ansible.lua b/public/nvim/.nvim/lua/plugins/lang/ansible.lua deleted file mode 100644 index 91f34df..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/ansible.lua +++ /dev/null @@ -1,21 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "yaml" }) - end - end, - }, - - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - opts.servers.ansiblels = {} - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/bash.lua b/public/nvim/.nvim/lua/plugins/lang/bash.lua deleted file mode 100644 index 141ca1c..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/bash.lua +++ /dev/null @@ -1,41 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "bash" }) - end - end, - }, - - { - "jose-elias-alvarez/null-ls.nvim", - opts = function(_, opts) - if type(opts) == "table" then - opts.sources = opts.sources or {} - local null_ls = require("null-ls") - vim.list_extend(opts.sources, { - null_ls.builtins.code_actions.shellcheck, -- Diagnostics handled by Bash LS - null_ls.builtins.formatting.shfmt, - }) - end - end, - }, - - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - -- Just here because it doesn't work with the default node - -- https://github.com/bash-lsp/bash-language-server/issues/418 - local brew_prefix = vim.fn.systemlist("brew --prefix")[1] - local bashls_script_name = "bash-language-server" - local bashls_script_path = vim.fn.systemlist("which " .. bashls_script_name)[1] - local bashls_cmd = { brew_prefix .. "/opt/node@16/bin/node", bashls_script_path, "start" } - opts.servers.bashls = { cmd = bashls_cmd } - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/c.lua b/public/nvim/.nvim/lua/plugins/lang/c.lua deleted file mode 100644 index 5b54a9d..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/c.lua +++ /dev/null @@ -1,20 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "c" }) - end - end, - }, - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - opts.servers.clangd = {} - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/dockerfile.lua b/public/nvim/.nvim/lua/plugins/lang/dockerfile.lua deleted file mode 100644 index ca3ccc2..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/dockerfile.lua +++ /dev/null @@ -1,24 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "dockerfile" }) - end - end, - }, - - { - "jose-elias-alvarez/null-ls.nvim", - opts = function(_, opts) - if type(opts) == "table" then - opts.sources = opts.sources or {} - local null_ls = require("null-ls") - vim.list_extend(opts.sources, { - null_ls.builtins.diagnostics.hadolint, - }) - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/go.lua b/public/nvim/.nvim/lua/plugins/lang/go.lua deleted file mode 100644 index 7e7fa03..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/go.lua +++ /dev/null @@ -1,65 +0,0 @@ -return { - { - "fatih/vim-go", - init = function() - vim.g.go_fmt_command = "gofumpt" - end, - ft = { "go" }, - }, - - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { - "go", - "gomod", - "gosum", - }) - end - end, - }, - - { - "jose-elias-alvarez/null-ls.nvim", - opts = function(_, opts) - if type(opts) == "table" then - opts.sources = opts.sources or {} - local null_ls = require("null-ls") - vim.list_extend(opts.sources, { - null_ls.builtins.diagnostics.golangci_lint, - null_ls.builtins.formatting.gofumpt, -- Just here because gopls integrated gofumpt doesn't work - }) - end - end, - }, - - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - opts.servers.gopls = { - -- Because integrated gofumpt doesn't work - -- I disable formatting for gopls - -- Formatting is handled with gofumpt by: - -- - null-ls on format request - -- - vim-go on save - on_attach = function(client, _) - client.server_capabilities.documentFormattingProvider = false - client.server_capabilities.documentRangeFormattingProvider = false - end, - cmd = { "gopls", "-remote=auto", "serve" }, -- Shared with vim-go's gopls instance - settings = { - gopls = { - buildFlags = { "-tags=integration,unit" }, -- To make packages with those build flags actually work with the LSP - semanticTokens = false, - gofumpt = true, -- gofumpt formatting, doesn't work - }, - }, - } - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/groovy.lua b/public/nvim/.nvim/lua/plugins/lang/groovy.lua deleted file mode 100644 index 1ab404d..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/groovy.lua +++ /dev/null @@ -1,38 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "groovy" }) - end - end, - }, - - { - "jose-elias-alvarez/null-ls.nvim", - opts = function(_, opts) - if type(opts) == "table" then - opts.sources = opts.sources or {} - local null_ls = require("null-ls") - vim.list_extend(opts.sources, { - null_ls.builtins.diagnostics.npm_groovy_lint, - null_ls.builtins.formatting.npm_groovy_lint, - }) - end - end, - }, - - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - local groovyls_path = "/Users/christian.segundo/git/groovy-language-server" - local groovyls_app_path = "build/libs/app-all.jar" - local groovyls_cmd = { "java", "-jar", groovyls_path .. "/" .. groovyls_app_path } - opts.servers.groovyls = { cmd = groovyls_cmd } - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/helm.lua b/public/nvim/.nvim/lua/plugins/lang/helm.lua deleted file mode 100644 index 6b303ec..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/helm.lua +++ /dev/null @@ -1,6 +0,0 @@ -return { - { - "towolf/vim-helm", - ft = { "yaml" }, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/jq.lua b/public/nvim/.nvim/lua/plugins/lang/jq.lua deleted file mode 100644 index a9a41c6..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/jq.lua +++ /dev/null @@ -1,21 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "jq" }) - end - end, - }, - - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - opts.servers.jqls = {} - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/json.lua b/public/nvim/.nvim/lua/plugins/lang/json.lua deleted file mode 100644 index 1d2d073..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/json.lua +++ /dev/null @@ -1,21 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "json" }) - end - end, - }, - - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - opts.servers.jsonls = {} - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/jsonnet.lua b/public/nvim/.nvim/lua/plugins/lang/jsonnet.lua deleted file mode 100644 index dff2e4b..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/jsonnet.lua +++ /dev/null @@ -1,26 +0,0 @@ -return { - { - "google/vim-jsonnet", - ft = { "jsonnet" }, - }, - - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "jsonnet" }) - end - end, - }, - - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - opts.servers.jsonnet_ls = {} - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/ledger.lua b/public/nvim/.nvim/lua/plugins/lang/ledger.lua deleted file mode 100644 index bc265e1..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/ledger.lua +++ /dev/null @@ -1,25 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "ledger" }) - end - end, - }, - { - "ledger/vim-ledger", - ft = { "ldg", "ledger", "journal" }, - }, - -- TODO - --{ - --"hrsh7th/nvim-cmp", - --opts = function(_, opts) - --if type(opts) == "table" then - --opts.sources = opts.sources or {} - --vim.list_extend(opts.sources, { name = "ledger" }) - --end - --end, - --}, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/lua.lua b/public/nvim/.nvim/lua/plugins/lang/lua.lua deleted file mode 100644 index 5e08867..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/lua.lua +++ /dev/null @@ -1,46 +0,0 @@ -return { - { "folke/neodev.nvim", lazy = true, opts = {} }, - - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "lua" }) - end - end, - }, - - { - "jose-elias-alvarez/null-ls.nvim", - opts = function(_, opts) - if type(opts) == "table" then - opts.sources = opts.sources or {} - local null_ls = require("null-ls") - vim.list_extend(opts.sources, { - null_ls.builtins.diagnostics.selene, - null_ls.builtins.formatting.stylua, - }) - end - end, - }, - - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - opts.on_attach = opts.on_attach or {} - opts.servers.lua_ls = { - on_attach = function(client, _) - client.server_capabilities.documentFormattingProvider = false - client.server_capabilities.documentRangeFormattingProvider = false - end, - } - end - end, - dependencies = { - "folke/neodev.nvim", - }, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/markdown.lua b/public/nvim/.nvim/lua/plugins/lang/markdown.lua deleted file mode 100644 index cfa6fd2..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/markdown.lua +++ /dev/null @@ -1,76 +0,0 @@ -return { - { - "iamcco/markdown-preview.nvim", - build = "cd app && npm install", - init = function() - vim.g.mkdp_filetypes = { "markdown" } - end, - ft = { "markdown" }, - }, - - { - "mzlogin/vim-markdown-toc", - init = function() - vim.g.vmt_auto_update_on_save = 0 - vim.g.vmt_dont_insert_fence = 1 - end, - ft = { "markdown" }, - }, - - { - "dbridges/vim-markdown-runner", - cmd = { "MarkdownRunner", "MarkdownRunnerInsert" }, - config = function() - vim.api.nvim_set_keymap("n", "r", "MarkdownRunner", { noremap = false, silent = true }) - vim.api.nvim_set_keymap("n", "R", "MarkdownRunnerInsert", { noremap = false, silent = true }) - end, - ft = { "markdown" }, - }, - - { - "preservim/vim-markdown", - dependencies = { "godlygeek/tabular" }, - init = function() - -- All concealing is handled by Treesitter - vim.g.vim_markdown_conceal = 0 - vim.g.vim_markdown_conceal_code_blocks = 0 - vim.g.vim_markdown_frontmatter = 0 - vim.g.vim_markdown_strikethrough = 0 - - vim.g.vim_markdown_auto_insert_bullets = 0 - vim.g.vim_markdown_new_list_item_indent = 0 - vim.g.vim_markdown_folding_disabled = 1 - end, - ft = { "markdown" }, - }, - - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { - "markdown_inline", - "markdown", - }) - end - end, - }, - - { - "jose-elias-alvarez/null-ls.nvim", - opts = function(_, opts) - if type(opts) == "table" then - opts.sources = opts.sources or {} - local null_ls = require("null-ls") - vim.list_extend(opts.sources, { - null_ls.builtins.diagnostics.markdownlint_cli2, - null_ls.builtins.diagnostics.vale, - null_ls.builtins.formatting.prettierd.with({ - filetypes = { "markdown" }, - }), - }) - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/perl.lua b/public/nvim/.nvim/lua/plugins/lang/perl.lua deleted file mode 100644 index 6ec7220..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/perl.lua +++ /dev/null @@ -1,36 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "perl" }) - end - end, - }, - - { - "jose-elias-alvarez/null-ls.nvim", - opts = function(_, opts) - if type(opts) == "table" then - opts.sources = opts.sources or {} - local null_ls = require("null-ls") - vim.list_extend(opts.sources, { - -- perlls is supposed to use perltidy for formatting, but it doesn't - -- work not sure why. - null_ls.builtins.formatting.perltidy, - }) - end - end, - }, - - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - opts.servers.perlls = {} - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/promql.lua b/public/nvim/.nvim/lua/plugins/lang/promql.lua deleted file mode 100644 index 5589b89..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/promql.lua +++ /dev/null @@ -1,19 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "promql" }) - end - end, - }, - - { - name = "promqlfmt.nvim", - url = "https://git.segundo.io/nvim/promqlfmt.nvim", - --dir = "/Users/christian.segundo/git/promql.nvim", - --dev = true, - cmd = { "Promqlfmt" }, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/swift.lua b/public/nvim/.nvim/lua/plugins/lang/swift.lua deleted file mode 100644 index d7f6d33..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/swift.lua +++ /dev/null @@ -1,35 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "swift" }) - end - end, - }, - - { - "jose-elias-alvarez/null-ls.nvim", - opts = function(_, opts) - if type(opts) == "table" then - opts.sources = opts.sources or {} - local null_ls = require("null-ls") - vim.list_extend(opts.sources, { - null_ls.builtins.diagnostics.swiftlint, - null_ls.builtins.formatting.swiftformat, - }) - end - end, - }, - - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - opts.servers.sourcekit = {} - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/terraform.lua b/public/nvim/.nvim/lua/plugins/lang/terraform.lua deleted file mode 100644 index e7ccff4..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/terraform.lua +++ /dev/null @@ -1,40 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { - "hcl", - "terraform", - }) - end - end, - }, - - { - "jose-elias-alvarez/null-ls.nvim", - opts = function(_, opts) - if type(opts) == "table" then - opts.sources = opts.sources or {} - local null_ls = require("null-ls") - vim.list_extend(opts.sources, { - null_ls.builtins.diagnostics.tfsec, - null_ls.builtins.formatting.terraform_fmt.with({ - extra_filetypes = { "hcl" }, - }), - }) - end - end, - }, - - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - opts.servers.terraformls = {} - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/typescript.lua b/public/nvim/.nvim/lua/plugins/lang/typescript.lua deleted file mode 100644 index f21c876..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/typescript.lua +++ /dev/null @@ -1,34 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "typescript", "javascript" }) - end - end, - }, - - { - "jose-elias-alvarez/null-ls.nvim", - opts = function(_, opts) - if type(opts) == "table" then - opts.sources = opts.sources or {} - local null_ls = require("null-ls") - vim.list_extend(opts.sources, { - null_ls.builtins.code_actions.eslint_d, - }) - end - end, - }, - - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - opts.servers.tsserver = {} - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/yaml.lua b/public/nvim/.nvim/lua/plugins/lang/yaml.lua deleted file mode 100644 index 83af09e..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/yaml.lua +++ /dev/null @@ -1,59 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "yaml" }) - end - end, - }, - - { - "jose-elias-alvarez/null-ls.nvim", - opts = function(_, opts) - if type(opts) == "table" then - opts.sources = opts.sources or {} - local null_ls = require("null-ls") - vim.list_extend(opts.sources, { - null_ls.builtins.diagnostics.yamllint, - }) - end - end, - }, - - { - --"someone-stole-my-name/yaml-companion.nvim", - dev = true, - dir = "/Users/christian.segundo/git/nvim_plugins/yaml-companion.nvim", - dependencies = { - "nvim-lua/plenary.nvim", - "nvim-telescope/telescope.nvim", - }, - init = function() - require("telescope").load_extension("yaml_schema") - end, - ft = { "yaml" }, - }, - - { - "neovim/nvim-lspconfig", - --dependencies = { "someone-stole-my-name/yaml-companion.nvim" }, - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - opts.servers.yamlls = require("yaml-companion").setup() - end - end, - }, - - { - "rafamadriz/friendly-snippets", - opts = function(_, opts) - if type(opts) == "table" then - opts.include = opts.include or {} - vim.list_extend(opts.include, { "yaml" }) - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lang/zig.lua b/public/nvim/.nvim/lua/plugins/lang/zig.lua deleted file mode 100644 index 1970797..0000000 --- a/public/nvim/.nvim/lua/plugins/lang/zig.lua +++ /dev/null @@ -1,40 +0,0 @@ -return { - { - "nvim-treesitter/nvim-treesitter", - opts = function(_, opts) - if type(opts) == "table" then - opts.ensure_installed = opts.ensure_installed or {} - vim.list_extend(opts.ensure_installed, { "zig" }) - end - end, - }, - - { - "jose-elias-alvarez/null-ls.nvim", - opts = function(_, opts) - if type(opts) == "table" then - opts.sources = opts.sources or {} - local null_ls = require("null-ls") - vim.list_extend(opts.sources, { - null_ls.builtins.formatting.zigfmt, - }) - end - end, - }, - - { - "neovim/nvim-lspconfig", - opts = function(_, opts) - if type(opts) == "table" then - opts.servers = opts.servers or {} - opts.on_attach = opts.on_attach or {} - opts.servers.zls = { - on_attach = function(client, _) - client.server_capabilities.documentFormattingProvider = false - client.server_capabilities.documentRangeFormattingProvider = false - end, - } - end - end, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lsp/cmp.lua b/public/nvim/.nvim/lua/plugins/lsp/cmp.lua deleted file mode 100644 index 004c265..0000000 --- a/public/nvim/.nvim/lua/plugins/lsp/cmp.lua +++ /dev/null @@ -1,97 +0,0 @@ -return { - "hrsh7th/nvim-cmp", - opts = { - sources = { - { name = "ledger" }, - { - name = "luasnip", - option = { - show_autosnippets = true, - use_show_condition = true, - }, - }, - { name = "nvim_lsp", priority = 1 }, - { name = "nvim_lsp_signature_help" }, - { name = "nvim_lua" }, - { name = "path" }, - { name = "emoji" }, - }, - formatting = { - format = { - mode = "symbol_text", - maxwidth = 50, - before = function(entry, vim_item) - return vim_item - end, - menu = { - buffer = "[Buffer]", - nvim_lsp = "[LSP]", - luasnip = "[LuaSnip]", - nvim_lua = "[Lua]", - latex_symbols = "[Latex]", - }, - }, - }, - }, - config = function(_, opts) - local cmp = require("cmp") - local luasnip = require("luasnip") - local lspkind = require("lspkind") - cmp.setup({ - sources = opts.sources, - --experimental = { ghost_text = { hl_group = "Comment" } }, - snippet = { - expand = function(args) - require("luasnip").lsp_expand(args.body) - end, - }, - formatting = { format = lspkind.cmp_format(opts.formatting.format) }, - mapping = { - [""] = cmp.mapping(function(fallback) - if cmp.visible() then - cmp.select_prev_item() - elseif luasnip.jumpable(-1) then - luasnip.jump(-1) - else - fallback() - end - end, { "i", "s" }), - [""] = cmp.mapping(function(fallback) - if cmp.visible() then - cmp.select_next_item() - elseif luasnip.expand_or_jumpable() then - luasnip.expand_or_jump() - else - fallback() - end - end, { "i", "s" }), - [""] = cmp.mapping(function(fallback) - if luasnip.choice_active() then - luasnip.change_choice(1) - else - fallback() - end - end, { "i", "s" }), - [""] = 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, -- Automatically select first item on CR - }), - }, - }) - end, - dependencies = { - { "L3MON4D3/LuaSnip" }, - { "hrsh7th/cmp-emoji" }, - { "hrsh7th/cmp-nvim-lsp" }, - { "hrsh7th/cmp-nvim-lsp-signature-help" }, - { "hrsh7th/cmp-nvim-lua" }, - { "hrsh7th/cmp-path" }, - { "onsails/lspkind.nvim" }, - { "saadparwaiz1/cmp_luasnip" }, - { "someone-stole-my-name/cmp-ledger" }, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lsp/config.lua b/public/nvim/.nvim/lua/plugins/lsp/config.lua deleted file mode 100644 index 579cfec..0000000 --- a/public/nvim/.nvim/lua/plugins/lsp/config.lua +++ /dev/null @@ -1,45 +0,0 @@ -return { - { - "neovim/nvim-lspconfig", - event = { "BufReadPre", "BufNewFile" }, - opts = { servers = {} }, - config = function(_, opts) - local add_hook_after = require("lspconfig.util").add_hook_after - local on_attach = function(client, bufnr) - require("nvim-navic").attach(client, bufnr) - end - - for lsp, lsp_opts in pairs(opts.servers) do - lsp_opts = lsp_opts or {} - if lsp_opts.on_attach ~= nil then - lsp_opts["on_attach"] = add_hook_after(on_attach, lsp_opts.on_attach) - end - lsp_opts["capabilities"] = require("cmp_nvim_lsp").default_capabilities( - lsp_opts.capabilities or {} - ) - require("lspconfig")[lsp].setup(lsp_opts) - end - end, - init = function() - vim.diagnostic.config({ - float = { - source = "always", - format = function(diagnostic) - -- should work for any LSP, see: https://github.com/neovim/neovim/pull/17510 - if diagnostic.code then - return string.format( - "(%s) %s", - diagnostic.code, - diagnostic.message - ) - end - return diagnostic.message - end, - }, - }) - end, - dependencies = { - { "SmiteshP/nvim-navic", opts = { highlight = true } }, - }, - }, -} diff --git a/public/nvim/.nvim/lua/plugins/lsp/null-ls.lua b/public/nvim/.nvim/lua/plugins/lsp/null-ls.lua deleted file mode 100644 index 5f71af7..0000000 --- a/public/nvim/.nvim/lua/plugins/lsp/null-ls.lua +++ /dev/null @@ -1,5 +0,0 @@ -return { - "jose-elias-alvarez/null-ls.nvim", - opts = { sources = {}, debug = false }, - dependencies = { "nvim-lua/plenary.nvim" }, -} diff --git a/public/nvim/.nvim/lua/plugins/lsp/trouble.lua b/public/nvim/.nvim/lua/plugins/lsp/trouble.lua deleted file mode 100644 index 207edb5..0000000 --- a/public/nvim/.nvim/lua/plugins/lsp/trouble.lua +++ /dev/null @@ -1,9 +0,0 @@ -return { - { - "folke/trouble.nvim", - dependencies = { "nvim-tree/nvim-web-devicons" }, - config = function() - require("trouble").setup({}) - end, - }, -} diff --git a/public/nvim/.nvim/lua/snippets/lua.lua b/public/nvim/.nvim/lua/snippets/lua.lua deleted file mode 100644 index dbec22a..0000000 --- a/public/nvim/.nvim/lua/snippets/lua.lua +++ /dev/null @@ -1,3 +0,0 @@ -return { - s("ignore", t("-- foo $0")), -} diff --git a/public/nvim/.nvim/lua/snippets/sh/bash-find.lua b/public/nvim/.nvim/lua/snippets/sh/bash-find.lua deleted file mode 100644 index be56beb..0000000 --- a/public/nvim/.nvim/lua/snippets/sh/bash-find.lua +++ /dev/null @@ -1,32 +0,0 @@ -local is_bash = function() - local shebang = vim.api.nvim_buf_get_lines(0, 0, 1, true) or {} - if shebang[1] and string.find(shebang[1], "bash") then - return true - end - return false -end - -return { - s( - { trig = "find-xargs", dscr = "" }, - fmt( -- The snippet code actually looks like the equation environment it produces. - [[ - find <> \ - -type <> \ - -name '*.<>' \ - -print0 | xargs -0 -r -P 0 <> - ]], - { - i(1, "."), -- search directory - c(2, { t("f"), t("d") }), -- file or directory - i(3, "ext"), -- file extension - i(4, "echo"), -- xaargs command - }, - { delimiters = "<>" } - ), - { - show_condition = is_bash, - condition = is_bash, - } - ), -} diff --git a/public/nvim/.nvim/lua/snippets/sh/bash-misc.lua b/public/nvim/.nvim/lua/snippets/sh/bash-misc.lua deleted file mode 100644 index f3a11eb..0000000 --- a/public/nvim/.nvim/lua/snippets/sh/bash-misc.lua +++ /dev/null @@ -1,16 +0,0 @@ -return { - s({ - trig = "no-source", - dscr = "Exit with an error if script is being sourced", - }, { - t({ - 'if [[ "${0}" != "${BASH_SOURCE[0]}" ]]; then', - '\techo "Error: script ${BASH_SOURCE[0]} is not supported to be sourced!"', - "\treturn 1", - "fi", - }), - }), -} - - - -- cgit v1.2.3