diff --git a/init.lua b/init.lua index b98ffc6198a..08fc0dd4cd8 100644 --- a/init.lua +++ b/init.lua @@ -115,7 +115,7 @@ vim.o.showmode = false -- Remove this option if you want your OS clipboard to remain independent. -- See `:help 'clipboard'` vim.schedule(function() - vim.o.clipboard = 'unnamedplus' + vim.opt.clipboard = 'unnamed' end) -- Enable break indent @@ -674,7 +674,26 @@ require('lazy').setup({ -- clangd = {}, -- gopls = {}, -- pyright = {}, - -- rust_analyzer = {}, + -- pylsp = {}, + --ty = {}, + --ruff = {}, + zuban = {}, + r_language_server = {}, + rust_analyzer = { + ['rust_analyzer'] = { + settings = { + diagnostic = { enable = false }, + checkOnSave = { enable = false }, + }, + }, + }, + bacon = {}, + ['bacon-ls'] = { + init_options = { + updateOnSave = true, + updateOnSaveWaitMillis = 1000, + }, + }, -- ... etc. See `:help lspconfig-all` for a list of all the pre-configured LSPs -- -- Some languages (like typescript) have entire language plugins that can be useful: @@ -729,6 +748,7 @@ require('lazy').setup({ -- by the server configuration above. Useful when disabling -- certain features of an LSP (for example, turning off formatting for ts_ls) server.capabilities = vim.tbl_deep_extend('force', {}, capabilities, server.capabilities or {}) + require('lspconfig')[server_name].setup(server) end, }, @@ -881,20 +901,17 @@ require('lazy').setup({ -- 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', + 'catppuccin/nvim', + name = 'catppuccin', priority = 1000, -- Make sure to load this before all the other start plugins. config = function() - ---@diagnostic disable-next-line: missing-fields - require('tokyonight').setup { - styles = { - comments = { italic = false }, -- Disable italics in comments - }, - } - -- 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' + vim.cmd.colorscheme 'catppuccin-macchiato' + + -- You can configure highlights by doing something like: + vim.cmd.hi 'Comment gui=none' end, }, @@ -974,17 +991,17 @@ require('lazy').setup({ -- Uncomment any of the lines below to enable them (you will need to restart nvim). -- -- require 'kickstart.plugins.debug', - -- require 'kickstart.plugins.indent_line', + require 'kickstart.plugins.indent_line', -- require 'kickstart.plugins.lint', -- require 'kickstart.plugins.autopairs', - -- require 'kickstart.plugins.neo-tree', + require 'kickstart.plugins.neo-tree', -- require 'kickstart.plugins.gitsigns', -- adds gitsigns recommend keymaps -- NOTE: The import below can automatically add your own plugins, configuration, etc from `lua/custom/plugins/*.lua` -- 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. - -- { import = 'custom.plugins' }, + { import = 'custom.plugins' }, -- -- For additional information with loading, sourcing and examples see `:help lazy.nvim-🔌-plugin-spec` -- Or use telescope! @@ -1014,3 +1031,15 @@ require('lazy').setup({ -- The line beneath this is called `modeline`. See `:help modeline` -- vim: ts=2 sts=2 sw=2 et +-- + +-- Gopass +vim.api.nvim_create_autocmd({ 'BufNewFile', 'BufRead' }, { + pattern = '/private/**/gopass**', + callback = function() + vim.opt_local.swapfile = false + vim.opt_local.backup = false + vim.opt_local.undofile = false + vim.opt_local.shadafile = '' + end, +}) diff --git a/lua/custom/plugins/nvim-repl.lua b/lua/custom/plugins/nvim-repl.lua new file mode 100644 index 00000000000..d6cc2a3e527 --- /dev/null +++ b/lua/custom/plugins/nvim-repl.lua @@ -0,0 +1,21 @@ +return { + 'pappasam/nvim-repl', + lazy = false, + init = function() + vim.g['repl_filetype_commands'] = { + bash = 'bash', + javascript = 'node', + haskell = 'ghci', + python = 'ipython --no-autoindent', + r = 'R', + sh = 'sh', + vim = 'nvim --clean -ERM', + zsh = 'zsh', + } + end, + keys = { + { 'sc', '(ReplSendCell)', mode = 'n', desc = 'Send Repl Cell' }, + { 'sl', '(ReplSendLine)', mode = 'n', desc = 'Send Repl Line' }, + { 'sr', '(ReplSendVisual)', mode = 'v', desc = 'Send Repl Visual Selection' }, + }, +} diff --git a/lua/custom/plugins/vim-language-nextflow.lua b/lua/custom/plugins/vim-language-nextflow.lua new file mode 100644 index 00000000000..f681cd7949e --- /dev/null +++ b/lua/custom/plugins/vim-language-nextflow.lua @@ -0,0 +1,3 @@ +return { + 'nextflow-io/vim-language-nextflow', +}