From 4c35ad40ed234c12be238a8e609068d91f89eac4 Mon Sep 17 00:00:00 2001 From: Andre Raposo Date: Sun, 5 Jan 2025 15:34:36 -0300 Subject: [PATCH] =?UTF-8?q?remove=20pacotes=20desnecess=C3=A1rios=20e=20ad?= =?UTF-8?q?iciona=20markview?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- init.lua | 58 ++++++++++++++------------ lua/custom/plugins/copilot.lua | 13 ------ lua/custom/plugins/lualine.lua | 29 ------------- lua/custom/plugins/markview.lua | 9 ++++ lua/custom/plugins/noice.lua | 27 ------------ lua/custom/plugins/snacks.lua | 20 +++++++++ lua/custom/plugins/trouble.lua | 47 --------------------- lua/custom/plugins/venv-selector.lua | 13 ------ lua/custom/plugins/vimtex.lua | 5 --- lua/custom/plugins/wilder.lua | 61 +++++++++++++++++++++++++--- lua/custom/plugins/zen-mode.lua | 6 --- lua/kickstart/plugins/neo-tree.lua | 36 +++------------- 12 files changed, 121 insertions(+), 203 deletions(-) delete mode 100644 lua/custom/plugins/copilot.lua delete mode 100644 lua/custom/plugins/lualine.lua create mode 100644 lua/custom/plugins/markview.lua delete mode 100644 lua/custom/plugins/noice.lua create mode 100644 lua/custom/plugins/snacks.lua delete mode 100644 lua/custom/plugins/trouble.lua delete mode 100644 lua/custom/plugins/venv-selector.lua delete mode 100644 lua/custom/plugins/vimtex.lua delete mode 100644 lua/custom/plugins/zen-mode.lua diff --git a/init.lua b/init.lua index 8b6d63f6..63aeadbb 100644 --- a/init.lua +++ b/init.lua @@ -8,7 +8,7 @@ vim.g.maplocalleader = ' ' vim.g.have_nerd_font = true -- Set global theme -vim.g.theme = 'oxocarbon' +vim.g.theme = 'adwaita' -- [[ Setting options ]] -- See `:help vim.opt` @@ -527,7 +527,7 @@ require('lazy').setup({ -- For example, to see the options for `lua_ls`, you could go to: https://luals.github.io/wiki/settings/ local servers = { -- clangd = {}, - -- gopls = {}, + gopls = {}, pyright = { settings = { pyright = { autoImportCompletion = true }, @@ -782,41 +782,28 @@ require('lazy').setup({ end, }, - { -- You can easily change to a different colorscheme. - -- Change the name of the colorscheme plugin below, and then - -- change the command in the config to whatever the name of that colorscheme is. - -- - -- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`. - 'folke/tokyonight.nvim', - priority = 1000, -- Make sure to load this before all the other start plugins. - -- init = function() - -- -- Load the colorscheme here. - -- -- Like many other themes, this one has different styles, and you could load - -- -- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'. - -- vim.cmd.colorscheme 'tokyonight-night' - -- - -- -- You can configure highlights by doing something like: - -- vim.cmd.hi 'Comment gui=none' - -- end, - }, { - 'Mofiqul/adwaita.nvim', + 'nyoom-engineering/oxocarbon.nvim', lazy = false, priority = 1000, config = function() vim.cmd.colorscheme(vim.g.theme) end, }, - { - 'uloco/bluloco.nvim', - lazy = false, - priority = 1000, - dependencies = { 'rktjmp/lush.nvim' }, - }, + { 'nyoom-engineering/oxocarbon.nvim', lazy = false, priority = 1000, + config = function() + vim.cmd.colorscheme(vim.g.theme) + end, + }, + + { + 'Mofiqul/adwaita.nvim', + lazy = false, + priority = 1000, }, -- Highlight todo, notes, etc in comments { 'folke/todo-comments.nvim', event = 'VimEnter', dependencies = { 'nvim-lua/plenary.nvim' }, opts = { signs = false } }, @@ -840,6 +827,22 @@ require('lazy').setup({ require('mini.surround').setup() require('mini.icons').setup() + + -- Simple and easy statusline. + -- You could remove this setup call if you don't like it, + -- and try some other statusline plugin + local statusline = require 'mini.statusline' + -- set use_icons to true if you have a Nerd Font + statusline.setup { use_icons = vim.g.have_nerd_font } + + -- You can configure sections in the statusline by overriding their + -- default behavior. For example, here we set the section for + -- cursor location to LINE:COLUMN + ---@diagnostic disable-next-line: duplicate-set-field + statusline.section_location = function() + return '%2l:%-2v' + end + -- ... and there is more! -- Check out: https://github.com/echasnovski/mini.nvim end, @@ -905,7 +908,7 @@ require('lazy').setup({ -- This is the easiest way to modularize your config. -- -- Uncomment the following line and add your plugins to `lua/custom/plugins/*.lua` to get going. - -- For additional information, see `:help lazy.nvim-lazy.nvim-structuring-your-plugins` + -- For additional information, see `:help lazy.nvim-lazy.nvim-structuring-your-plugins` { import = 'custom.plugins' }, }, { ui = { @@ -931,6 +934,7 @@ require('lazy').setup({ -- Setup python provider vim.g.python3_host_prog = '$HOME/.asdf/shims/python' +vim.g.python_host_prog = '$HOME/.asdf/shims/python' -- The line beneath this is called `modeline`. See `:help modeline` -- vim: ts=2 sts=2 sw=2 et diff --git a/lua/custom/plugins/copilot.lua b/lua/custom/plugins/copilot.lua deleted file mode 100644 index 0869a0a1..00000000 --- a/lua/custom/plugins/copilot.lua +++ /dev/null @@ -1,13 +0,0 @@ -return { - 'zbirenbaum/copilot.lua', - cmd = 'Copilot', - build = ':Copilot auth', - opts = { - suggestion = { enabled = false }, - panel = { enabled = false }, - filetypes = { - markdown = true, - help = true, - }, - }, -} diff --git a/lua/custom/plugins/lualine.lua b/lua/custom/plugins/lualine.lua deleted file mode 100644 index 19ccd391..00000000 --- a/lua/custom/plugins/lualine.lua +++ /dev/null @@ -1,29 +0,0 @@ -return { - 'nvim-lualine/lualine.nvim', - dependencies = { 'nvim-tree/nvim-web-devicons' }, - opts = { - options = { - icons_enabled = vim.g.have_nerd_font, - theme = 'auto', - - -- Sections - section_separators = '', - component_separators = '|', - }, - sections = { - lualine_a = { 'branch', { 'diff', colored = false } }, - lualine_b = { { 'diagnostics', sources = { 'nvim_diagnostic' } } }, - lualine_c = { { 'filename', file_status = true, newfile_status = true, path = 0 } }, - lualine_x = { 'encoding', 'fileformat', 'filetype' }, - lualine_y = { - { - require('noice').api.status.mode.get, - cond = require('noice').api.status.mode.has, - color = { fg = '#ff9e64' }, - }, - 'mode', - }, - lualine_z = { 'location' }, - }, - }, -} diff --git a/lua/custom/plugins/markview.lua b/lua/custom/plugins/markview.lua new file mode 100644 index 00000000..540ba566 --- /dev/null +++ b/lua/custom/plugins/markview.lua @@ -0,0 +1,9 @@ +return { + 'OXY2DEV/markview.nvim', + lazy = false, + + dependencies = { + 'nvim-treesitter/nvim-treesitter', + 'nvim-tree/nvim-web-devicons', + }, +} diff --git a/lua/custom/plugins/noice.lua b/lua/custom/plugins/noice.lua deleted file mode 100644 index 6bd22f80..00000000 --- a/lua/custom/plugins/noice.lua +++ /dev/null @@ -1,27 +0,0 @@ -return { - 'folke/noice.nvim', - event = 'VeryLazy', - opts = { - 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 - cmdline = { - view = 'cmdline', - }, - presets = { - long_message_to_split = false, -- long messages will be sent to a split - inc_rename = true, -- enables an input dialog for inc-rename.nvim - lsp_doc_border = false, -- add a border to hover docs and signature help - }, - }, - dependencies = { - -- if you lazy-load any plugin below, make sure to add proper `module="..."` entries - 'MunifTanjim/nui.nvim', - }, -} diff --git a/lua/custom/plugins/snacks.lua b/lua/custom/plugins/snacks.lua new file mode 100644 index 00000000..38bc9aeb --- /dev/null +++ b/lua/custom/plugins/snacks.lua @@ -0,0 +1,20 @@ +return { + 'folke/snacks.nvim', + priority = 1000, + lazy = false, + + opts = { + -- your configuration comes here + -- or leave it empty to use the default settings + -- refer to the configuration section below + animate = { enabled = true }, + bigfile = { enabled = true }, + bufdelete = { enabled = true }, + dim = { enabled = true }, + notifier = { enabled = true }, + notify = { enabled = true }, + rename = { enabled = true }, + quickfile = { enabled = true }, + scroll = { enabled = true }, + }, +} diff --git a/lua/custom/plugins/trouble.lua b/lua/custom/plugins/trouble.lua deleted file mode 100644 index 02983b1b..00000000 --- a/lua/custom/plugins/trouble.lua +++ /dev/null @@ -1,47 +0,0 @@ -return { - 'folke/trouble.nvim', - cmd = { 'Trouble' }, - opts = { - modes = { - lsp = { - win = { position = 'right' }, - }, - }, - }, - keys = { - { 'xx', 'Trouble diagnostics toggle', desc = 'Diagnostics (Trouble)' }, - { 'xX', 'Trouble diagnostics toggle filter.buf=0', desc = 'Buffer Diagnostics (Trouble)' }, - { 'cs', 'Trouble symbols toggle', desc = 'Symbols (Trouble)' }, - { 'cS', 'Trouble lsp toggle', desc = 'LSP references/definitions/... (Trouble)' }, - { 'xL', 'Trouble loclist toggle', desc = 'Location List (Trouble)' }, - { 'xQ', 'Trouble qflist toggle', desc = 'Quickfix List (Trouble)' }, - { - '[q', - function() - if require('trouble').is_open() then - require('trouble').prev { skip_groups = true, jump = true } - else - local ok, err = pcall(vim.cmd.cprev) - if not ok then - vim.notify(err, vim.log.levels.ERROR) - end - end - end, - desc = 'Previous Trouble/Quickfix Item', - }, - { - ']q', - function() - if require('trouble').is_open() then - require('trouble').next { skip_groups = true, jump = true } - else - local ok, err = pcall(vim.cmd.cnext) - if not ok then - vim.notify(err, vim.log.levels.ERROR) - end - end - end, - desc = 'Next Trouble/Quickfix Item', - }, - }, -} diff --git a/lua/custom/plugins/venv-selector.lua b/lua/custom/plugins/venv-selector.lua deleted file mode 100644 index 45f03e9c..00000000 --- a/lua/custom/plugins/venv-selector.lua +++ /dev/null @@ -1,13 +0,0 @@ -return { - 'linux-cultist/venv-selector.nvim', - dependencies = { - 'neovim/nvim-lspconfig', - 'mfussenegger/nvim-dap', - 'mfussenegger/nvim-dap-python', --optional - }, - lazy = false, - branch = 'regexp', -- This is the regexp branch, use this for the new version - config = function() - require('venv-selector').setup() - end, -} diff --git a/lua/custom/plugins/vimtex.lua b/lua/custom/plugins/vimtex.lua deleted file mode 100644 index 84db24f5..00000000 --- a/lua/custom/plugins/vimtex.lua +++ /dev/null @@ -1,5 +0,0 @@ -return { - 'lervag/vimtex', - lazy = false, - opt = {}, -} diff --git a/lua/custom/plugins/wilder.lua b/lua/custom/plugins/wilder.lua index b5ee5a7e..66cae566 100644 --- a/lua/custom/plugins/wilder.lua +++ b/lua/custom/plugins/wilder.lua @@ -1,12 +1,63 @@ --- if true then --- return {} --- end - return { 'gelguy/wilder.nvim', - opts = {}, + dependencies = { + 'romgrk/fzy-lua-native', + }, config = function() local wilder = require 'wilder' wilder.setup { modes = { ':', '/', '?' } } + -- Disable Python remote plugin + wilder.set_option('use_python_remote_plugin', 0) + + wilder.set_option('pipeline', { + wilder.branch( + wilder.cmdline_pipeline { + fuzzy = 1, + fuzzy_filter = wilder.lua_fzy_filter(), + }, + wilder.vim_search_pipeline() + ), + }) + + local gradient = { + '#f4468f', + '#fd4a85', + '#ff507a', + '#ff566f', + '#ff5e63', + '#ff6658', + '#ff704e', + '#ff7a45', + '#ff843d', + '#ff9036', + '#f89b31', + '#efa72f', + '#e6b32e', + '#dcbe30', + '#d2c934', + '#c8d43a', + '#bfde43', + '#b6e84e', + '#aff05b', + } + + for i, fg in ipairs(gradient) do + gradient[i] = wilder.make_hl('WilderGradient' .. i, 'Pmenu', { { a = 1 }, { a = 1 }, { foreground = fg } }) + end + + wilder.set_option( + 'renderer', + wilder.wildmenu_renderer { + highlights = { + gradient = gradient, -- must be set + -- selected_gradient key can be set to apply gradient highlighting for the selected candidate. + }, + + highlighter = wilder.highlighter_with_gradient { + wilder.lua_pcre2_highlighter(), -- requires `luarocks install pcre2` + wilder.lua_fzy_highlighter(), -- requires fzy-lua-native vim plugin found + }, + } + ) end, } diff --git a/lua/custom/plugins/zen-mode.lua b/lua/custom/plugins/zen-mode.lua deleted file mode 100644 index f4352fdf..00000000 --- a/lua/custom/plugins/zen-mode.lua +++ /dev/null @@ -1,6 +0,0 @@ -return { - 'folke/zen-mode.nvim', - opts = { - -- pass - }, -} diff --git a/lua/kickstart/plugins/neo-tree.lua b/lua/kickstart/plugins/neo-tree.lua index cb2e1b81..bdb847d9 100644 --- a/lua/kickstart/plugins/neo-tree.lua +++ b/lua/kickstart/plugins/neo-tree.lua @@ -1,6 +1,9 @@ -- Neo-tree is a Neovim plugin to browse the file system -- https://github.com/nvim-neo-tree/neo-tree.nvim +-- Neo-tree is a Neovim plugin to browse the file system +-- https://github.com/nvim-neo-tree/neo-tree.nvim + return { 'nvim-neo-tree/neo-tree.nvim', version = '*', @@ -8,47 +11,18 @@ return { 'nvim-lua/plenary.nvim', 'nvim-tree/nvim-web-devicons', -- not strictly required, but recommended 'MunifTanjim/nui.nvim', - '3rd/image.nvim', }, cmd = 'Neotree', keys = { - { '~', ':Neotree reveal', { desc = 'NeoTree reveal' } }, + { '\\', ':Neotree reveal', desc = 'NeoTree reveal', silent = true }, }, opts = { filesystem = { window = { mappings = { - ['~'] = 'close_window', + ['\\'] = 'close_window', }, }, }, - default_component_configs = { - name = { - trailing_slash = true, - 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 = '', - }, - }, - indent = { - with_expanders = true, -- if nil and file nesting is enabled, will enable expanders - expander_collapsed = '', - expander_expanded = '', - expander_highlight = 'NeoTreeExpander', - }, - }, }, }