updated ocaml and c#
This commit is contained in:
parent
a7e2fe3ea0
commit
7648c06f07
|
|
@ -54,6 +54,7 @@
|
||||||
"popui.nvim": { "branch": "master", "commit": "4d903e46fdb5eef25fa79ef1b598f5340a2674b0" },
|
"popui.nvim": { "branch": "master", "commit": "4d903e46fdb5eef25fa79ef1b598f5340a2674b0" },
|
||||||
"popup.nvim": { "branch": "master", "commit": "b7404d35d5d3548a82149238289fa71f7f6de4ac" },
|
"popup.nvim": { "branch": "master", "commit": "b7404d35d5d3548a82149238289fa71f7f6de4ac" },
|
||||||
"presence.nvim": { "branch": "main", "commit": "87c857a56b7703f976d3a5ef15967d80508df6e6" },
|
"presence.nvim": { "branch": "main", "commit": "87c857a56b7703f976d3a5ef15967d80508df6e6" },
|
||||||
|
"roslyn.nvim": { "branch": "main", "commit": "e284f0e6c34b01cd1db9fdb71c75ae85d732a43b" },
|
||||||
"statuscol.nvim": { "branch": "main", "commit": "93d8bcda516fc86e11c03f9ef577bae9a72fba0e" },
|
"statuscol.nvim": { "branch": "main", "commit": "93d8bcda516fc86e11c03f9ef577bae9a72fba0e" },
|
||||||
"supermaven-nvim": { "branch": "main", "commit": "d71257f431e190d9236d7f30da4c2d659389e91f" },
|
"supermaven-nvim": { "branch": "main", "commit": "d71257f431e190d9236d7f30da4c2d659389e91f" },
|
||||||
"tailwind-tools.nvim": { "branch": "master", "commit": "48523580c6af449a7a57610ce5596c716cf4363a" },
|
"tailwind-tools.nvim": { "branch": "master", "commit": "48523580c6af449a7a57610ce5596c716cf4363a" },
|
||||||
|
|
|
||||||
|
|
@ -28,3 +28,16 @@ set.signcolumn = "auto:2"
|
||||||
|
|
||||||
-- set leader
|
-- set leader
|
||||||
vim.g.mapleader = " "
|
vim.g.mapleader = " "
|
||||||
|
|
||||||
|
vim.filetype.add(
|
||||||
|
{
|
||||||
|
extension = {
|
||||||
|
zsh = "sh",
|
||||||
|
sh = "sh"
|
||||||
|
},
|
||||||
|
filename = {
|
||||||
|
[".zshrc"] = "sh",
|
||||||
|
[".zshenv"] = "sh"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
|
||||||
|
|
@ -80,7 +80,8 @@ require("lazy").setup(
|
||||||
"williamboman/mason.nvim",
|
"williamboman/mason.nvim",
|
||||||
"williamboman/mason-lspconfig.nvim",
|
"williamboman/mason-lspconfig.nvim",
|
||||||
"neovim/nvim-lspconfig",
|
"neovim/nvim-lspconfig",
|
||||||
"jay-babu/mason-null-ls.nvim"
|
"jay-babu/mason-null-ls.nvim",
|
||||||
|
"seblj/roslyn.nvim"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -63,16 +63,35 @@ require("formatter").setup(
|
||||||
stdin = true
|
stdin = true
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
},
|
||||||
|
xml = {
|
||||||
|
function()
|
||||||
|
return {
|
||||||
|
exe = "xmllint",
|
||||||
|
args = {"--format", "-"},
|
||||||
|
stdin = true
|
||||||
|
}
|
||||||
|
end
|
||||||
|
},
|
||||||
|
cs = {
|
||||||
|
function()
|
||||||
|
return {
|
||||||
|
exe = "dotnet-csharpier",
|
||||||
|
args = {"--write-stdout"},
|
||||||
|
stdin = true
|
||||||
|
}
|
||||||
|
end
|
||||||
|
},
|
||||||
|
-- ocaml
|
||||||
|
ocaml = {
|
||||||
|
function()
|
||||||
|
return {
|
||||||
|
exe = "ocamlformat",
|
||||||
|
args = {"--name", vim.api.nvim_buf_get_name(0), "-"},
|
||||||
|
stdin = true
|
||||||
|
}
|
||||||
|
end
|
||||||
}
|
}
|
||||||
-- cs = {
|
|
||||||
-- function()
|
|
||||||
-- return {
|
|
||||||
-- exe = "dotnet",
|
|
||||||
-- args = {"csharpier", "--write-stdout"},
|
|
||||||
-- stdin = true
|
|
||||||
-- }
|
|
||||||
-- end
|
|
||||||
-- }
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
@ -81,7 +100,7 @@ vim.api.nvim_exec(
|
||||||
[[
|
[[
|
||||||
augroup FormatAutogroup
|
augroup FormatAutogroup
|
||||||
autocmd!
|
autocmd!
|
||||||
autocmd BufWritePost *.h,*.cpp,*.rs,*.lua,*.tsx,*.ts,*.js,*.jsx,*.json,*.jsonc,*.swift FormatWrite
|
autocmd BufWritePost *.cs,*.h,*.cpp,*.rs,*.lua,*.tsx,*.ts,*.js,*.jsx,*.json,*.jsonc,*.swift,*.xml,*.sln,*.csproj,*.ml FormatWrite
|
||||||
augroup END
|
augroup END
|
||||||
]],
|
]],
|
||||||
true
|
true
|
||||||
|
|
@ -90,7 +109,7 @@ local formatGrp = vim.api.nvim_create_augroup("Format", {clear = true})
|
||||||
vim.api.nvim_create_autocmd(
|
vim.api.nvim_create_autocmd(
|
||||||
"BufWritePre",
|
"BufWritePre",
|
||||||
{
|
{
|
||||||
pattern = "*.cs,*.php",
|
pattern = "*.php",
|
||||||
command = "lua vim.lsp.buf.format { async = false }",
|
command = "lua vim.lsp.buf.format { async = false }",
|
||||||
group = formatGrp
|
group = formatGrp
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -26,13 +26,13 @@ local common_servers = {
|
||||||
"lua_ls",
|
"lua_ls",
|
||||||
"html",
|
"html",
|
||||||
"vimls",
|
"vimls",
|
||||||
"yamlls"
|
"yamlls",
|
||||||
|
"ocamllsp"
|
||||||
}
|
}
|
||||||
local extra_servers = {
|
local extra_servers = {
|
||||||
"vtsls",
|
"vtsls",
|
||||||
"eslint",
|
"eslint",
|
||||||
"jsonls",
|
"jsonls",
|
||||||
"omnisharp",
|
|
||||||
"rust_analyzer",
|
"rust_analyzer",
|
||||||
"tailwindcss"
|
"tailwindcss"
|
||||||
}
|
}
|
||||||
|
|
@ -199,115 +199,107 @@ nvim_lsp.tailwindcss.setup {
|
||||||
debounce_text_changes = 150
|
debounce_text_changes = 150
|
||||||
},
|
},
|
||||||
capabilities = capabilities,
|
capabilities = capabilities,
|
||||||
-- on_init = function(client)
|
|
||||||
-- local path = client.workspace_folders and client.workspace_folders[1] and client.workspace_folders[1].name
|
|
||||||
-- local config_path = path .. "/.vscode/settings.json"
|
|
||||||
-- if vim.uv.fs_stat(config_path) then
|
|
||||||
-- local file = vim.fn.readfile(config_path)
|
|
||||||
-- local vscode_settings = vim.fn.json_decode(file)
|
|
||||||
-- client.config.settings =
|
|
||||||
-- vim.tbl_deep_extend(
|
|
||||||
-- "force",
|
|
||||||
-- client.config.settings,
|
|
||||||
-- {
|
|
||||||
-- tailwindCSS = {
|
|
||||||
-- rootFontSize = vscode_settings["tailwindCSS.rootFontSize"]
|
|
||||||
-- }
|
|
||||||
-- }
|
|
||||||
-- )
|
|
||||||
-- client.notify(vim.lsp.protocol.Methods.workspace_didChangeConfiguration, {settings = client.config.settings})
|
|
||||||
-- end
|
|
||||||
-- end,
|
|
||||||
settings = tailwindcss_settings
|
settings = tailwindcss_settings
|
||||||
}
|
}
|
||||||
|
|
||||||
nvim_lsp.omnisharp.setup {
|
require("roslyn").setup(
|
||||||
cmd = {"OmniSharp"},
|
{
|
||||||
enable_editorconfig_support = true,
|
config = {},
|
||||||
enable_roslyn_analyzers = true,
|
exe = {
|
||||||
enable_import_completion = true,
|
"dotnet",
|
||||||
on_attach = function(client, bufnr)
|
vim.fs.joinpath(vim.fn.stdpath("data"), "roslyn", "Microsoft.CodeAnalysis.LanguageServer.dll")
|
||||||
client.server_capabilities.semanticTokensProvider = {
|
},
|
||||||
full = vim.empty_dict(),
|
filewatching = true
|
||||||
legend = {
|
}
|
||||||
tokenModifiers = {"static_symbol"},
|
)
|
||||||
tokenTypes = {
|
|
||||||
"comment",
|
-- nvim_lsp.omnisharp.setup {
|
||||||
"excluded_code",
|
-- cmd = {"OmniSharp"},
|
||||||
"identifier",
|
-- enable_editorconfig_support = true,
|
||||||
"keyword",
|
-- enable_roslyn_analyzers = true,
|
||||||
"keyword_control",
|
-- enable_import_completion = true,
|
||||||
"number",
|
-- on_attach = function(client, bufnr)
|
||||||
"operator",
|
-- client.server_capabilities.semanticTokensProvider = {
|
||||||
"operator_overloaded",
|
-- full = vim.empty_dict(),
|
||||||
"preprocessor_keyword",
|
-- legend = {
|
||||||
"string",
|
-- tokenModifiers = {"static_symbol"},
|
||||||
"whitespace",
|
-- tokenTypes = {
|
||||||
"text",
|
-- "comment",
|
||||||
"static_symbol",
|
-- "excluded_code",
|
||||||
"preprocessor_text",
|
-- "identifier",
|
||||||
"punctuation",
|
-- "keyword",
|
||||||
"string_verbatim",
|
-- "keyword_control",
|
||||||
"string_escape_character",
|
-- "number",
|
||||||
"class_name",
|
-- "operator",
|
||||||
"delegate_name",
|
-- "operator_overloaded",
|
||||||
"enum_name",
|
-- "preprocessor_keyword",
|
||||||
"interface_name",
|
-- "string",
|
||||||
"module_name",
|
-- "whitespace",
|
||||||
"struct_name",
|
-- "text",
|
||||||
"type_parameter_name",
|
-- "static_symbol",
|
||||||
"field_name",
|
-- "preprocessor_text",
|
||||||
"enum_member_name",
|
-- "punctuation",
|
||||||
"constant_name",
|
-- "string_verbatim",
|
||||||
"local_name",
|
-- "string_escape_character",
|
||||||
"parameter_name",
|
-- "class_name",
|
||||||
"method_name",
|
-- "delegate_name",
|
||||||
"extension_method_name",
|
-- "enum_name",
|
||||||
"property_name",
|
-- "interface_name",
|
||||||
"event_name",
|
-- "module_name",
|
||||||
"namespace_name",
|
-- "struct_name",
|
||||||
"label_name",
|
-- "type_parameter_name",
|
||||||
"xml_doc_comment_attribute_name",
|
-- "field_name",
|
||||||
"xml_doc_comment_attribute_quotes",
|
-- "enum_member_name",
|
||||||
"xml_doc_comment_attribute_value",
|
-- "constant_name",
|
||||||
"xml_doc_comment_cdata_section",
|
-- "local_name",
|
||||||
"xml_doc_comment_comment",
|
-- "parameter_name",
|
||||||
"xml_doc_comment_delimiter",
|
-- "method_name",
|
||||||
"xml_doc_comment_entity_reference",
|
-- "extension_method_name",
|
||||||
"xml_doc_comment_name",
|
-- "property_name",
|
||||||
"xml_doc_comment_processing_instruction",
|
-- "event_name",
|
||||||
"xml_doc_comment_text",
|
-- "namespace_name",
|
||||||
"xml_literal_attribute_name",
|
-- "label_name",
|
||||||
"xml_literal_attribute_quotes",
|
-- "xml_doc_comment_attribute_name",
|
||||||
"xml_literal_attribute_value",
|
-- "xml_doc_comment_attribute_quotes",
|
||||||
"xml_literal_cdata_section",
|
-- "xml_doc_comment_attribute_value",
|
||||||
"xml_literal_comment",
|
-- "xml_doc_comment_cdata_section",
|
||||||
"xml_literal_delimiter",
|
-- "xml_doc_comment_comment",
|
||||||
"xml_literal_embedded_expression",
|
-- "xml_doc_comment_delimiter",
|
||||||
"xml_literal_entity_reference",
|
-- "xml_doc_comment_entity_reference",
|
||||||
"xml_literal_name",
|
-- "xml_doc_comment_name",
|
||||||
"xml_literal_processing_instruction",
|
-- "xml_doc_comment_processing_instruction",
|
||||||
"xml_literal_text",
|
-- "xml_doc_comment_text",
|
||||||
"regex_comment",
|
-- "xml_literal_attribute_name",
|
||||||
"regex_character_class",
|
-- "xml_literal_attribute_quotes",
|
||||||
"regex_anchor",
|
-- "xml_literal_attribute_value",
|
||||||
"regex_quantifier",
|
-- "xml_literal_cdata_section",
|
||||||
"regex_grouping",
|
-- "xml_literal_comment",
|
||||||
"regex_alternation",
|
-- "xml_literal_delimiter",
|
||||||
"regex_text",
|
-- "xml_literal_embedded_expression",
|
||||||
"regex_self_escaped_character",
|
-- "xml_literal_entity_reference",
|
||||||
"regex_other_escape"
|
-- "xml_literal_name",
|
||||||
}
|
-- "xml_literal_processing_instruction",
|
||||||
},
|
-- "xml_literal_text",
|
||||||
range = true
|
-- "regex_comment",
|
||||||
}
|
-- "regex_character_class",
|
||||||
on_attach(client, bufnr)
|
-- "regex_anchor",
|
||||||
end,
|
-- "regex_quantifier",
|
||||||
flags = {
|
-- "regex_grouping",
|
||||||
debounce_text_changes = 150
|
-- "regex_alternation",
|
||||||
},
|
-- "regex_text",
|
||||||
capabilities = capabilities
|
-- "regex_self_escaped_character",
|
||||||
}
|
-- "regex_other_escape"
|
||||||
|
-- }
|
||||||
|
-- },
|
||||||
|
-- range = true
|
||||||
|
-- }
|
||||||
|
-- on_attach(client, bufnr)
|
||||||
|
-- end,
|
||||||
|
-- flags = {
|
||||||
|
-- debounce_text_changes = 150
|
||||||
|
-- },
|
||||||
|
-- capabilities = capabilities
|
||||||
|
-- }
|
||||||
|
|
||||||
nvim_lsp.rust_analyzer.setup {
|
nvim_lsp.rust_analyzer.setup {
|
||||||
on_attach = on_attach,
|
on_attach = on_attach,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue