add mason-lspconfig, osc52 copy

This commit is contained in:
Mira Kristipati 2024-07-02 20:14:45 -04:00
parent ba85f279ae
commit d1313ec362
4 changed files with 31 additions and 10 deletions

View file

@ -73,3 +73,15 @@ vim.o.foldlevelstart = 99
vim.opt.wildmode = { "list", "longest" }
vim.opt.wildmenu = true
vim.opt.autoread = true
vim.g.clipboard = {
name = "OSC 52",
copy = {
["+"] = require("vim.ui.clipboard.osc52").copy "+",
["*"] = require("vim.ui.clipboard.osc52").copy "*",
},
paste = {
["+"] = require("vim.ui.clipboard.osc52").paste "+",
["*"] = require("vim.ui.clipboard.osc52").paste "*",
},
}

View file

@ -1,8 +1,13 @@
local lspconfig = require "lspconfig"
local on_attach = require("nvchad.configs.lspconfig").on_attach
local on_attach = require("nvchad.configs.lspconfig").on_init
local capabilities = require("nvchad.configs.lspconfig").capabilities
local capabilities
require("mason-lspconfig").setup()
require("mason-lspconfig").setup_handlers {
function(name)
lspconfig[name].setup {}
end,
}
-- if you just want default config for the servers then put them in a table
local servers = {
"html",
@ -14,11 +19,13 @@ local servers = {
"lua_ls",
"docker_compose_language_service",
"ast_grep",
-- "basedpyright",
"pyright",
"bashls",
"css_variables",
"marksman",
"rust_analyzer",
"ruff",
"jdtls",
}
for _, lsp in ipairs(servers) do

View file

@ -4,15 +4,15 @@ local opts = {
debug = true,
sources = {
null_ls.builtins.code_actions.refactoring,
null_ls.builtins.diagnostics.mypy.with {
-- extra_args = { "--python-executable", virtual .. "/bin/python3" },
},
-- null_ls.builtins.diagnostics.mypy.with {
-- extra_args = { "--python-executable", virtual .. "/bin/python3" },
-- },
-- null_ls.builtins.diagnostics.flake8.with {
-- extra_args = { "--select", "E,W,F", "--ignore", "E501,E402,E722,W503", "--max-line-length", "150" },
-- },
-- null_ls.builtins.formatting.autoflake,
-- null_ls.builtins.formatting.autopep8.with {
-- extra_args = { "--select", "E,W,F", "--ignore", "E501,E402,E722,W503", "--max-line-length", "150" },
-- extra_args = { "--select", "E,W,F", "--ignore", "E501,E402,E722,W503", "--max-line-length", "150" },
-- },
-- Lua
null_ls.builtins.formatting.stylua,

View file

@ -7,6 +7,7 @@ return {
-- General Plugins --
---------------------
-- LSP Stuff
-- TODO: make these lang specific
{
"williamboman/mason.nvim",
-- opts = overrides.mason
@ -55,7 +56,7 @@ return {
end,
dependencies = {
"nvim-treesitter/nvim-treesitter", -- optional
"nvim-tree/nvim-web-devicons", -- optional
"nvim-tree/nvim-web-devicons", -- optional
},
},
{ "ThePrimeagen/refactoring.nvim" },
@ -75,6 +76,7 @@ return {
end, -- Override to setup mason-lspconfig
dependencies = {
"nvimdev/lspsaga.nvim",
"williamboman/mason-lspconfig.nvim",
},
lazy = false,
},
@ -106,7 +108,7 @@ return {
},
-- Delimiters
{ "Raimondi/delimitMate", lazy = false },
{ "Raimondi/delimitMate", lazy = false },
-- lazygit
{
"kdheepak/lazygit.nvim",
@ -116,7 +118,7 @@ return {
lazy = false,
},
-- fzf
{ "junegunn/fzf.vim", lazy = false },
{ "junegunn/fzf.vim", lazy = false },
{
"nvim-telescope/telescope.nvim",
config = function()