Compare commits
No commits in common. "7ff3f7b450972ae169b78fe640aa996257b89326" and "3d8e3134e9adb956e6d975a3e6094562b7ef1f9d" have entirely different histories.
7ff3f7b450
...
3d8e3134e9
|
|
@ -1,3 +0,0 @@
|
|||
{
|
||||
"format.enable": false
|
||||
}
|
||||
10
init.lua
10
init.lua
|
|
@ -1,18 +1,10 @@
|
|||
-- This file simply bootstraps the installation of Lazy.nvim and then calls other files for execution
|
||||
-- This file doesn't necessarily need to be touched, BE CAUTIOUS editing this file and proceed at your own risk.
|
||||
local lazypath = vim.env.LAZY or vim.fn.stdpath "data" .. "/lazy/lazy.nvim"
|
||||
|
||||
if not (vim.env.LAZY or (vim.uv or vim.loop).fs_stat(lazypath)) then
|
||||
-- stylua: ignore
|
||||
local result = vim.fn.system({ "git", "clone", "--filter=blob:none", "https://github.com/folke/lazy.nvim.git", "--branch=stable", lazypath })
|
||||
if vim.v.shell_error ~= 0 then
|
||||
-- stylua: ignore
|
||||
vim.api.nvim_echo({ { ("Error cloning lazy.nvim:\n%s\n"):format(result), "ErrorMsg" }, { "Press any key to exit...", "MoreMsg" } }, true, {})
|
||||
vim.fn.getchar()
|
||||
vim.cmd.quit()
|
||||
end
|
||||
vim.fn.system({ "git", "clone", "--filter=blob:none", "https://github.com/folke/lazy.nvim.git", "--branch=stable", lazypath })
|
||||
end
|
||||
|
||||
vim.opt.rtp:prepend(lazypath)
|
||||
|
||||
-- validate that lazy is available
|
||||
|
|
|
|||
|
|
@ -1,77 +1,82 @@
|
|||
{
|
||||
"AstroNvim": { "branch": "main", "commit": "c399f7f46daa010db1b70f6f7062a6a85216e1de" },
|
||||
"LuaSnip": { "branch": "master", "commit": "642b0c595e11608b4c18219e93b88d7637af27bc" },
|
||||
"actions-preview.nvim": { "branch": "master", "commit": "2b604b2e8e662c03b716436f6ffebcb19663e66a" },
|
||||
"aerial.nvim": { "branch": "master", "commit": "645d108a5242ec7b378cbe643eb6d04d4223f034" },
|
||||
"AstroNvim": { "branch": "main", "commit": "7fd58328e2bc91d5cad606ee48fdf924fca6ea3e" },
|
||||
"Comment.nvim": { "branch": "master", "commit": "e30b7f2008e52442154b66f7c519bfd2f1e32acb" },
|
||||
"LuaSnip": { "branch": "master", "commit": "5a1e39223db9a0498024a77b8441169d260c8c25" },
|
||||
"actions-preview.nvim": { "branch": "master", "commit": "cb938c25edaac38d362555f19244a9cb85d561e8" },
|
||||
"aerial.nvim": { "branch": "master", "commit": "5c4e2da4486da5f9b798ea9a0f1fc5c6bcd3d9cf" },
|
||||
"animation.nvim": { "branch": "main", "commit": "fb77091ab72ec9971aee0562e7081182527aaa6a" },
|
||||
"astrocommunity": { "branch": "main", "commit": "39edda038177a8b8d4838536160cfbd006b540dc" },
|
||||
"astrocore": { "branch": "main", "commit": "b061e0c185cd5fecbac7489151a98117ce799a47" },
|
||||
"astrolsp": { "branch": "main", "commit": "ebc1676127b3bfbd46e3e26589b104853cac3730" },
|
||||
"astrocommunity": { "branch": "main", "commit": "175a21dc270a2abd65b7059ddb7ff166212d1e0f" },
|
||||
"astrocore": { "branch": "main", "commit": "5052189882442cf71e04ad2d5472ee31bfe6a5cf" },
|
||||
"astrolsp": { "branch": "main", "commit": "0befe28a4ea96e46b7f7c01e4a634c04225ba55a" },
|
||||
"astrotheme": { "branch": "main", "commit": "cf0e65a7b3ce2f830b052f4da937729eee1e7a7d" },
|
||||
"astroui": { "branch": "main", "commit": "920dd5df6629a9076a11ea10f0d21f4225203585" },
|
||||
"astroui": { "branch": "main", "commit": "4943abbd42674b43249313afe83b91065a40e4be" },
|
||||
"better-escape.nvim": { "branch": "master", "commit": "199dcc2643dec5d8dbdab4ec672cf405224dcb3b" },
|
||||
"blink.cmp": { "branch": "main", "commit": "78336bc89ee5365633bcf754d93df01678b5c08f" },
|
||||
"blink.cmp": { "branch": "main", "commit": "451168851e8e2466bc97ee3e026c3dcb9141ce07" },
|
||||
"blink.compat": { "branch": "main", "commit": "2ed6d9a28b07fa6f3bface818470605f8896408c" },
|
||||
"catppuccin": { "branch": "main", "commit": "426dbebe06b5c69fd846ceb17b42e12f890aedf1" },
|
||||
"clangd_extensions.nvim": { "branch": "main", "commit": "872893cb061044a4cc7ced59c0f2fe2d70db4382" },
|
||||
"cmake-tools.nvim": { "branch": "master", "commit": "bac6ba2354a52c61f731c751cdb0f4e24669bf0d" },
|
||||
"catppuccin": { "branch": "main", "commit": "16408d203973da7e43fab87c6f9d3bf7fa98fa8b" },
|
||||
"clangd_extensions.nvim": { "branch": "main", "commit": "92b720768fad9d8a333a3cbb167f0bab550f9f50" },
|
||||
"cmake-tools.nvim": { "branch": "master", "commit": "e100f40b117381dadf42a34b0718f8e4350715b2" },
|
||||
"cmp-dap": { "branch": "master", "commit": "ea92773e84c0ad3288c3bc5e452ac91559669087" },
|
||||
"codecompanion.nvim": { "branch": "main", "commit": "fe792b30974893d8809b06c5e31c5c876c14bbc7" },
|
||||
"crates.nvim": { "branch": "main", "commit": "0f536967abd097d9a4275087483f15d012418740" },
|
||||
"codecompanion.nvim": { "branch": "main", "commit": "ed70638e9d0922177affc89a97c2d7bf338dac8f" },
|
||||
"crates.nvim": { "branch": "main", "commit": "ac9fa498a9edb96dc3056724ff69d5f40b898453" },
|
||||
"diffview.nvim": { "branch": "main", "commit": "4516612fe98ff56ae0415a259ff6361a89419b0a" },
|
||||
"friendly-snippets": { "branch": "main", "commit": "6cd7280adead7f586db6fccbd15d2cac7e2188b9" },
|
||||
"garbage-day.nvim": { "branch": "main", "commit": "2fcc56556281de8ee871a5f3beb9db7ab747ef32" },
|
||||
"gitsigns.nvim": { "branch": "main", "commit": "a462f416e2ce4744531c6256252dee99a7d34a83" },
|
||||
"gitsigns.nvim": { "branch": "main", "commit": "7010000889bfb6c26065e0b0f7f1e6aa9163edd9" },
|
||||
"guess-indent.nvim": { "branch": "main", "commit": "84a4987ff36798c2fc1169cbaff67960aed9776f" },
|
||||
"heirline.nvim": { "branch": "master", "commit": "fae936abb5e0345b85c3a03ecf38525b0828b992" },
|
||||
"homeassistant-nvim": { "branch": "main", "commit": "1484ec0ad211eaeefa977444e3c6d0987b20a349" },
|
||||
"hover.nvim": { "branch": "main", "commit": "e73c00da3a9c87a21d2a8ddf7ab4a39824bd5d56" },
|
||||
"image.nvim": { "branch": "master", "commit": "da2be65c153ba15a14a342b05591652a6df70d58" },
|
||||
"lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" },
|
||||
"lazydev.nvim": { "branch": "main", "commit": "ff2cbcba459b637ec3fd165a2be59b7bbaeedf0d" },
|
||||
"lazydev.nvim": { "branch": "main", "commit": "01bc2aacd51cf9021eb19d048e70ce3dd09f7f93" },
|
||||
"lsp-lens.nvim": { "branch": "main", "commit": "48bb1a7e271424c15f3d588d54adc9b7c319d977" },
|
||||
"lsp_signature.nvim": { "branch": "master", "commit": "a65b38f260cc3470a05b4afb84c8d868617d476d" },
|
||||
"lualine.nvim": { "branch": "master", "commit": "f5d2a8570f8b736ddb9bb4be504355bcd6e15ec8" },
|
||||
"lsp_signature.nvim": { "branch": "master", "commit": "af7e4074d85d785cf6614352ba9ad3b28a1f8a56" },
|
||||
"lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" },
|
||||
"magick": { "branch": "master", "commit": "6971fa700c4d392130492a3925344b51c7cc54aa" },
|
||||
"markdown-preview.nvim": { "branch": "master", "commit": "a923f5fc5ba36a3b17e289dc35dc17f66d0548ee" },
|
||||
"markview.nvim": { "branch": "main", "commit": "1861f959599ae03cfd59f56222a542035b0cd947" },
|
||||
"mason-lspconfig.nvim": { "branch": "main", "commit": "25f609e7fca78af7cede4f9fa3af8a94b1c4950b" },
|
||||
"mason-lspconfig.nvim": { "branch": "main", "commit": "1a31f824b9cd5bc6f342fc29e9a53b60d74af245" },
|
||||
"mason-null-ls.nvim": { "branch": "main", "commit": "2b8433f76598397fcc97318d410e0c4f7a4bea6a" },
|
||||
"mason-nvim-dap.nvim": { "branch": "main", "commit": "e51f9b259f066c4347f9a79ffde54c29a0619384" },
|
||||
"mason-tool-installer.nvim": { "branch": "main", "commit": "443f1ef8b5e6bf47045cb2217b6f748a223cf7dc" },
|
||||
"mason.nvim": { "branch": "main", "commit": "44d1e90e1f66e077268191e3ee9d2ac97cc18e65" },
|
||||
"middleclass": { "branch": "master", "commit": "9fab4d5bca67262614960960ca35c4740eb2be2c" },
|
||||
"mini.icons": { "branch": "main", "commit": "ff2e4f1d29f659cc2bad0f9256f2f6195c6b2428" },
|
||||
"mini.indentscope": { "branch": "main", "commit": "e0601f75aa5137a5a13bb92a988c9a300f5bd3de" },
|
||||
"mini.icons": { "branch": "main", "commit": "397ed3807e96b59709ef3292f0a3e253d5c1dc0a" },
|
||||
"mini.indentscope": { "branch": "main", "commit": "065c7713fb4cd0124fe1462f15f27feeb8b04406" },
|
||||
"neo-tree.nvim": { "branch": "main", "commit": "84c75e7a7e443586f60508d12fc50f90d9aee14e" },
|
||||
"none-ls.nvim": { "branch": "main", "commit": "7f9301e416533b5d74e2fb3b1ce5059eeaed748b" },
|
||||
"neoconf.nvim": { "branch": "main", "commit": "bbe36f4d60ed096282f564ddae4e781e420a8270" },
|
||||
"none-ls.nvim": { "branch": "main", "commit": "3c206dfedf5f1385e9d29f85ffaec7874358592a" },
|
||||
"nui.nvim": { "branch": "main", "commit": "f535005e6ad1016383f24e39559833759453564e" },
|
||||
"nvim-autopairs": { "branch": "master", "commit": "59bce2eef357189c3305e25bc6dd2d138c1683f5" },
|
||||
"nvim-dap": { "branch": "master", "commit": "45a69eba683a2c448dd9ecfc4de89511f0646b5f" },
|
||||
"nvim-autopairs": { "branch": "master", "commit": "c2a0dd0d931d0fb07665e1fedb1ea688da3b80b4" },
|
||||
"nvim-dap": { "branch": "master", "commit": "085386b9359ddf8d76ad89b98973b8e332dc5ba3" },
|
||||
"nvim-dap-python": { "branch": "master", "commit": "1808458eba2b18f178f990e01376941a42c7f93b" },
|
||||
"nvim-dap-ui": { "branch": "master", "commit": "1a66cabaa4a4da0be107d5eda6d57242f0fe7e49" },
|
||||
"nvim-dap-ui": { "branch": "master", "commit": "cf91d5e2d07c72903d052f5207511bf7ecdb7122" },
|
||||
"nvim-highlight-colors": { "branch": "main", "commit": "e2cb22089cc2358b2b995c09578224f142de6039" },
|
||||
"nvim-lsp-file-operations": { "branch": "master", "commit": "b9c795d3973e8eec22706af14959bc60c579e771" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "0203a9608d63eda57679b01e69f33a7b4c34b0d1" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "fa2662510d30b06168b6e2e6915518decde6bbac" },
|
||||
"nvim-nio": { "branch": "master", "commit": "21f5324bfac14e22ba26553caf69ec76ae8a7662" },
|
||||
"nvim-treesitter": { "branch": "main", "commit": "90cd6580e720caedacb91fdd587b747a6e77d61f" },
|
||||
"nvim-treesitter-textobjects": { "branch": "main", "commit": "851e865342e5a4cb1ae23d31caf6e991e1c99f1e" },
|
||||
"nvim-ts-autotag": { "branch": "main", "commit": "8e1c0a389f20bf7f5b0dd0e00306c1247bda2595" },
|
||||
"nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" },
|
||||
"nvim-treesitter-textobjects": { "branch": "master", "commit": "5ca4aaa6efdcc59be46b95a3e876300cfead05ef" },
|
||||
"nvim-ts-autotag": { "branch": "main", "commit": "db15f2e0df2f5db916e511e3fffb682ef2f6354f" },
|
||||
"nvim-ts-context-commentstring": { "branch": "main", "commit": "1b212c2eee76d787bbea6aa5e92a2b534e7b4f8f" },
|
||||
"nvim-ufo": { "branch": "main", "commit": "a5390706f510d39951dd581f6d2a972741b3fa26" },
|
||||
"nvim-vtsls": { "branch": "main", "commit": "0b5f73c9e50ce95842ea07bb3f05c7d66d87d14a" },
|
||||
"nvim-window-picker": { "branch": "main", "commit": "6382540b2ae5de6c793d4aa2e3fe6dbb518505ec" },
|
||||
"package-info.nvim": { "branch": "master", "commit": "52e407af634cd5d3add0dc916c517865850113a4" },
|
||||
"plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" },
|
||||
"remote-sshfs.nvim": { "branch": "main", "commit": "7a12a1677bbe96ca98f0c713448ac1f518ba09b7" },
|
||||
"remote-sshfs.nvim": { "branch": "main", "commit": "45502b3892774811153aeab5f7f9b0033c82005c" },
|
||||
"resession.nvim": { "branch": "master", "commit": "cc819b0489938d03e4f3532a583354f0287c015b" },
|
||||
"rustaceanvim": { "branch": "main", "commit": "7b8dd7abb9a7f442b356aa03714aefce09610339" },
|
||||
"rustaceanvim": { "branch": "master", "commit": "88575b98bb9937fb9983ddec5e532b67e75ce677" },
|
||||
"rustowl": { "branch": "main", "commit": "aaf7d15cc55ff6f48c577cdd6352d51fbc031aea" },
|
||||
"smart-splits.nvim": { "branch": "master", "commit": "0bd02161ee5c5378bf4133fcedf53d1fc4179e1d" },
|
||||
"smart-splits.nvim": { "branch": "master", "commit": "ddb23c1a1cf1507bda487cda7f6e4690965ef9f5" },
|
||||
"snacks.nvim": { "branch": "main", "commit": "e6fd58c82f2f3fcddd3fe81703d47d6d48fc7b9f" },
|
||||
"telescope.nvim": { "branch": "master", "commit": "48d2656e54d3e3953ae647153ccdaffa50d4d76b" },
|
||||
"telescope.nvim": { "branch": "master", "commit": "cfb85dcf7f822b79224e9e6aef9e8c794211b20b" },
|
||||
"todo-comments.nvim": { "branch": "main", "commit": "31e3c38ce9b29781e4422fc0322eb0a21f4e8668" },
|
||||
"toggleterm.nvim": { "branch": "main", "commit": "50ea089fc548917cc3cc16b46a8211833b9e3c7c" },
|
||||
"ts-comments.nvim": { "branch": "main", "commit": "123a9fb12e7229342f807ec9e6de478b1102b041" },
|
||||
"tsc.nvim": { "branch": "main", "commit": "e083bcf1e54bc3af7df92b33235efb334e8c782c" },
|
||||
"vim-illuminate": { "branch": "master", "commit": "0d1e93684da00ab7c057410fecfc24f434698898" },
|
||||
"which-key.nvim": { "branch": "main", "commit": "fcbf4eea17cb299c02557d576f0d568878e354a4" },
|
||||
"windows.nvim": { "branch": "main", "commit": "c7492552b23d0ab30325e90b56066ec51242adc8" },
|
||||
"yazi.nvim": { "branch": "main", "commit": "172bd64a4c2d3adbe2e0ef56289f47ffe139ca55" }
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@
|
|||
---@type LazySpec
|
||||
return {
|
||||
"AstroNvim/astrocommunity",
|
||||
version = "^20",
|
||||
{ import = "astrocommunity.pack.lua" },
|
||||
{ import = "astrocommunity.pack.rust" },
|
||||
{ import = "astrocommunity.pack.python" },
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
require("lazy").setup({
|
||||
{
|
||||
"AstroNvim/AstroNvim",
|
||||
version = "^6", -- Remove version tracking to elect for nightly AstroNvim
|
||||
version = "^5", -- Remove version tracking to elect for nightly AstroNvim
|
||||
import = "astronvim.plugins",
|
||||
opts = { -- AstroNvim options must be set here with the `import` key
|
||||
mapleader = " ", -- This ensures the leader key must be configured before Lazy is set up
|
||||
|
|
|
|||
|
|
@ -24,19 +24,6 @@ return {
|
|||
virtual_text = true,
|
||||
underline = true,
|
||||
},
|
||||
-- passed to `vim.filetype.add`
|
||||
filetypes = {
|
||||
-- see `:h vim.filetype.add` for usage
|
||||
extension = {
|
||||
foo = "fooscript",
|
||||
},
|
||||
filename = {
|
||||
[".foorc"] = "fooscript",
|
||||
},
|
||||
pattern = {
|
||||
[".*/etc/foo/.*"] = "fooscript",
|
||||
},
|
||||
},
|
||||
-- vim options can be configured here
|
||||
options = {
|
||||
opt = { -- vim.opt.<key>
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
if true then return {} end -- WARN: REMOVE THIS LINE TO ACTIVATE THIS FILE
|
||||
-- if true then return {} end -- WARN: REMOVE THIS LINE TO ACTIVATE THIS FILE
|
||||
|
||||
-- AstroLSP allows you to customize the features in AstroNvim's LSP configuration engine
|
||||
-- Configuration documentation can be found with `:h astrolsp`
|
||||
|
|
@ -10,93 +10,11 @@ return {
|
|||
"AstroNvim/astrolsp",
|
||||
---@type AstroLSPOpts
|
||||
opts = {
|
||||
features = {
|
||||
semantic_tokens = true,
|
||||
},
|
||||
formatting = {
|
||||
-- control auto formatting on save
|
||||
format_on_save = {
|
||||
enabled = true, -- enable or disable format on save globally
|
||||
allow_filetypes = { -- enable format on save for specified filetypes only
|
||||
-- "go",
|
||||
},
|
||||
ignore_filetypes = { -- disable format on save for specified filetypes
|
||||
-- "python",
|
||||
},
|
||||
},
|
||||
disabled = { -- disable formatting capabilities for the listed language servers
|
||||
-- disable lua_ls formatting capability if you want to use StyLua to format your lua code
|
||||
-- "lua_ls",
|
||||
disabled = {
|
||||
"volar",
|
||||
"vtsls",
|
||||
},
|
||||
timeout_ms = 1000, -- default format timeout
|
||||
-- filter = function(client) -- fully override the default formatting function
|
||||
-- return true
|
||||
-- end
|
||||
},
|
||||
-- enable servers that you already have installed without mason
|
||||
servers = {
|
||||
-- "pyright"
|
||||
},
|
||||
-- customize language server configuration passed to `vim.lsp.config`
|
||||
-- client specific configuration can also go in `lsp/` in your configuration root (see `:h lsp-config`)
|
||||
config = {
|
||||
-- ["*"] = { capabilities = {} }, -- modify default LSP client settings such as capabilities
|
||||
},
|
||||
-- customize how language servers are attached
|
||||
handlers = {
|
||||
-- a function with the key `*` modifies the default handler, functions takes the server name as the parameter
|
||||
-- ["*"] = function(server) vim.lsp.enable(server) end
|
||||
|
||||
-- the key is the server that is being setup with `vim.lsp.config`
|
||||
-- rust_analyzer = false, -- setting a handler to false will disable the set up of that language server
|
||||
},
|
||||
-- Configure buffer local auto commands to add when attaching a language server
|
||||
autocmds = {
|
||||
-- first key is the `augroup` to add the auto commands to (:h augroup)
|
||||
lsp_codelens_refresh = {
|
||||
-- Optional condition to create/delete auto command group
|
||||
-- can either be a string of a client capability or a function of `fun(client, bufnr): boolean`
|
||||
-- condition will be resolved for each client on each execution and if it ever fails for all clients,
|
||||
-- the auto commands will be deleted for that buffer
|
||||
cond = "textDocument/codeLens",
|
||||
-- cond = function(client, bufnr) return client.name == "lua_ls" end,
|
||||
-- list of auto commands to set
|
||||
{
|
||||
-- events to trigger
|
||||
event = { "InsertLeave", "BufEnter" },
|
||||
-- the rest of the autocmd options (:h nvim_create_autocmd)
|
||||
desc = "Refresh codelens (buffer)",
|
||||
callback = function(args)
|
||||
if require("astrolsp").config.features.codelens then vim.lsp.codelens.refresh { bufnr = args.buf } end
|
||||
end,
|
||||
},
|
||||
},
|
||||
},
|
||||
-- mappings to be set up on attaching of a language server
|
||||
mappings = {
|
||||
n = {
|
||||
-- a `cond` key can provided as the string of a server capability to be required to attach, or a function with `client` and `bufnr` parameters from the `on_attach` that returns a boolean
|
||||
gD = {
|
||||
function() vim.lsp.buf.declaration() end,
|
||||
desc = "Declaration of current symbol",
|
||||
cond = "textDocument/declaration",
|
||||
},
|
||||
["<Leader>uY"] = {
|
||||
function() require("astrolsp.toggles").buffer_semantic_tokens() end,
|
||||
desc = "Toggle LSP semantic highlight (buffer)",
|
||||
cond = function(client)
|
||||
return client.supports_method "textDocument/semanticTokens/full" and vim.lsp.semantic_tokens ~= nil
|
||||
end,
|
||||
},
|
||||
},
|
||||
},
|
||||
-- A custom `on_attach` function to be run after the default `on_attach` function
|
||||
-- takes two parameters `client` and `bufnr` (`:h lsp-attach`)
|
||||
on_attach = function(client, bufnr)
|
||||
-- this would disable semanticTokensProvider for all clients
|
||||
-- client.server_capabilities.semanticTokensProvider = nil
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,69 +0,0 @@
|
|||
-- if true then return {} end
|
||||
return {
|
||||
"mrcjkb/rustaceanvim",
|
||||
-- To avoid being surprised by breaking changes,
|
||||
-- I recommend you set a version range
|
||||
version = "^9",
|
||||
-- This plugin implements proper lazy-loading (see :h lua-plugin-lazy).
|
||||
-- No need for lazy.nvim to lazy-load it.
|
||||
lazy = false,
|
||||
}
|
||||
-- return {
|
||||
-- "mrcjkb/rustaceanvim",
|
||||
-- version = "^8",
|
||||
-- ft = "rust",
|
||||
-- specs = {
|
||||
-- {
|
||||
-- "AstroNvim/astrolsp",
|
||||
-- optional = true,
|
||||
-- ---@type AstroLSPOpts
|
||||
-- opts = {
|
||||
-- handlers = { rust_analyzer = false }, -- disable setup of `rust_analyzer`
|
||||
-- },
|
||||
-- },
|
||||
-- },
|
||||
-- opts = function()
|
||||
-- local adapter
|
||||
-- local codelldb_installed = pcall(function() return require("mason-registry").get_package "codelldb" end)
|
||||
-- local cfg = require "rustaceanvim.config"
|
||||
-- if codelldb_installed then
|
||||
-- local codelldb_path = vim.fn.exepath "codelldb"
|
||||
-- local this_os = vim.uv.os_uname().sysname
|
||||
--
|
||||
-- local liblldb_path = vim.fn.expand "$MASON/share/lldb"
|
||||
-- -- The path in windows is different
|
||||
-- if this_os:find "Windows" then
|
||||
-- liblldb_path = liblldb_path .. "\\bin\\lldb.dll"
|
||||
-- else
|
||||
-- -- The liblldb extension is .so for linux and .dylib for macOS
|
||||
-- liblldb_path = liblldb_path .. "/lib/liblldb" .. (this_os == "Linux" and ".so" or ".dylib")
|
||||
-- end
|
||||
-- adapter = cfg.get_codelldb_adapter(codelldb_path, liblldb_path)
|
||||
-- else
|
||||
-- adapter = cfg.get_codelldb_adapter()
|
||||
-- end
|
||||
--
|
||||
-- local astrolsp_opts = vim.lsp.config["rust_analyzer"] or {}
|
||||
-- local server = {
|
||||
-- ---@type table | (fun(project_root:string|nil, default_settings: table|nil):table) -- The rust-analyzer settings or a function that creates them.
|
||||
-- settings = function(project_root, default_settings)
|
||||
-- local astrolsp_settings = astrolsp_opts.settings or {}
|
||||
--
|
||||
-- local merge_table = require("astrocore").extend_tbl(default_settings or {}, astrolsp_settings)
|
||||
-- local ra = require "rustaceanvim.config.server"
|
||||
-- -- load_rust_analyzer_settings merges any found settings with the passed in default settings table and then returns that table
|
||||
-- return ra.load_rust_analyzer_settings(project_root, {
|
||||
-- settings_file_pattern = "rust-analyzer.json",
|
||||
-- default_settings = merge_table,
|
||||
-- })
|
||||
-- end,
|
||||
-- }
|
||||
-- local final_server = require("astrocore").extend_tbl(astrolsp_opts, server)
|
||||
-- return {
|
||||
-- server = final_server,
|
||||
-- dap = { adapter = adapter, load_rust_types = true },
|
||||
-- tools = { enable_clippy = false },
|
||||
-- }
|
||||
-- end,
|
||||
-- config = function(_, opts) vim.g.rustaceanvim = require("astrocore").extend_tbl(opts, vim.g.rustaceanvim) end,
|
||||
-- }
|
||||
|
|
@ -1,34 +1,19 @@
|
|||
-- if true then return {} end -- WARN: REMOVE THIS LINE TO ACTIVATE THIS FILE
|
||||
|
||||
-- Customize Treesitter
|
||||
-- --------------------
|
||||
-- Treesitter customizations are handled with AstroCore
|
||||
-- as nvim-treesitter simply provides a download utility for parsers
|
||||
|
||||
---@type LazySpec
|
||||
return {
|
||||
"AstroNvim/astrocore",
|
||||
---@type AstroCoreOpts
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
opts = {
|
||||
treesitter = {
|
||||
enabled = true,
|
||||
highlight = true, -- enable/disable treesitter based highlighting
|
||||
indent = true, -- enable/disable treesitter based indentation
|
||||
auto_install = true, -- enable/disable automatic installation of detected languages
|
||||
ensure_installed = {
|
||||
"lua",
|
||||
"vim",
|
||||
"vue",
|
||||
"html",
|
||||
"css",
|
||||
"javascript",
|
||||
"typescript",
|
||||
"tsx",
|
||||
"rust",
|
||||
"ron",
|
||||
"toml",
|
||||
-- add more arguments for adding more treesitter parsers
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -144,49 +144,4 @@ return {
|
|||
-- or leave empty for defaults
|
||||
},
|
||||
},
|
||||
-- You can disable default plugins as follows:
|
||||
-- { "max397574/better-escape.nvim", enabled = false },
|
||||
|
||||
-- You can also easily customize additional setup of plugins that is outside of the plugin's setup call
|
||||
-- {
|
||||
-- "L3MON4D3/LuaSnip",
|
||||
-- config = function(plugin, opts)
|
||||
-- -- add more custom luasnip configuration such as filetype extend or custom snippets
|
||||
-- local luasnip = require "luasnip"
|
||||
-- luasnip.filetype_extend("javascript", { "javascriptreact" })
|
||||
--
|
||||
-- -- include the default astronvim config that calls the setup call
|
||||
-- require "astronvim.plugins.configs.luasnip"(plugin, opts)
|
||||
-- end,
|
||||
-- },
|
||||
--
|
||||
-- {
|
||||
-- "windwp/nvim-autopairs",
|
||||
-- config = function(plugin, opts)
|
||||
-- require "astronvim.plugins.configs.nvim-autopairs"(plugin, opts) -- include the default astronvim config that calls the setup call
|
||||
-- -- add more custom autopairs configuration such as custom rules
|
||||
-- local npairs = require "nvim-autopairs"
|
||||
-- local Rule = require "nvim-autopairs.rule"
|
||||
-- local cond = require "nvim-autopairs.conds"
|
||||
-- npairs.add_rules(
|
||||
-- {
|
||||
-- Rule("$", "$", { "tex", "latex" })
|
||||
-- -- don't add a pair if the next character is %
|
||||
-- :with_pair(cond.not_after_regex "%%")
|
||||
-- -- don't add a pair if the previous character is xxx
|
||||
-- :with_pair(
|
||||
-- cond.not_before_regex("xxx", 3)
|
||||
-- )
|
||||
-- -- don't move right when repeat character
|
||||
-- :with_move(cond.none())
|
||||
-- -- don't delete if the next character is xx
|
||||
-- :with_del(cond.not_after_regex "xx")
|
||||
-- -- disable adding a newline when you press <cr>
|
||||
-- :with_cr(cond.none()),
|
||||
-- },
|
||||
-- -- disable for .vim files, but it work for another filetypes
|
||||
-- Rule("a", "a", "-vim")
|
||||
-- )
|
||||
-- end,
|
||||
-- },
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,18 @@
|
|||
if true then return end -- WARN: REMOVE THIS LINE TO ACTIVATE THIS FILE
|
||||
|
||||
-- This will run last in the setup process.
|
||||
-- This is just pure lua so anything that doesn't
|
||||
-- This will run last in the setup process and is a good place to configure
|
||||
-- things like custom filetypes. This is just pure lua so anything that doesn't
|
||||
-- fit in the normal config locations above can go here
|
||||
|
||||
-- Set up custom filetypes
|
||||
vim.filetype.add {
|
||||
extension = {
|
||||
foo = "fooscript",
|
||||
},
|
||||
filename = {
|
||||
["Foofile"] = "fooscript",
|
||||
},
|
||||
pattern = {
|
||||
["~/%.config/foo/.*"] = "fooscript",
|
||||
},
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue