Added launch.json schema support

This commit is contained in:
2025-08-06 11:36:27 +02:00
parent d143d30d9d
commit eb91fdd5d1
2 changed files with 21 additions and 2 deletions

View File

@@ -410,6 +410,8 @@ require('lazy').setup({
'saghen/blink.cmp',
-- Roslyn
{ 'seblyng/roslyn.nvim', ft = 'cs', opts = {} },
-- SchemaStores for yamlls and jsonls
'b0o/schemastore.nvim',
},
config = function()
vim.api.nvim_create_autocmd('LspAttach', {
@@ -612,7 +614,24 @@ require('lazy').setup({
},
html = {},
cssls = {},
jsonls = {},
jsonls = {
settings = {
json = {
schemas = require('schemastore').json.schemas {
extra = {
{
-- Can be found here: https://github.com/wraith13/vscode-schemas?tab=readme-ov-file
description = 'vscode launch.json schema',
fileMatch = '/.vscode/launch.json',
name = 'launch.json',
url = 'https://raw.githubusercontent.com/wraith13/vscode-schemas/refs/heads/master/en/latest/schemas/launch.json',
},
},
},
validate = { enable = true },
},
},
},
lua_ls = {
settings = {
Lua = {
@@ -678,7 +697,6 @@ require('lazy').setup({
'isort',
'black',
'prettierd',
'json-lsp',
})
require('mason-tool-installer').setup { ensure_installed = ensure_installed }
-- Installed LSPs are configured and enabled automatically with mason-lspconfig