#ifndef MAPS_H #define MAPS_H #include "./lsp.h" #include "./pch.h" #include "./ts_def.h" static const std::unordered_map kLsps = { {1, {"clangd", { "clangd", "--background-index", "--clang-tidy", "--completion-style=detailed", "--header-insertion=never", "--pch-storage=memory", "--limit-results=50", "--log=error", nullptr, }}}, }; static const std::unordered_map kLanguages = { {"bash", {"bash", LANG(bash)}}, {"c", {"c", LANG(c), 1}}, {"cpp", {"cpp", LANG(cpp), 1}}, {"h", {"h", LANG(cpp), 1}}, {"css", {"css", LANG(css)}}, {"fish", {"fish", LANG(fish)}}, {"go", {"go", LANG(go)}}, {"haskell", {"haskell", LANG(haskell)}}, {"html", {"html", LANG(html)}}, {"javascript", {"javascript", LANG(javascript)}}, {"json", {"json", LANG(json)}}, {"lua", {"lua", LANG(lua)}}, {"make", {"make", LANG(make)}}, {"python", {"python", LANG(python)}}, {"ruby", {"ruby", LANG(ruby)}}, {"diff", {"diff", LANG(diff)}}, {"embedded_template", {"embedded_template", LANG(embedded_template)}}, {"gdscript", {"gdscript", LANG(gdscript)}}, {"gitattributes", {"gitattributes", LANG(gitattributes)}}, {"gitignore", {"gitignore", LANG(gitignore)}}, {"gomod", {"gomod", LANG(gomod)}}, {"ini", {"ini", LANG(ini)}}, {"markdown", {"markdown", LANG(markdown)}}, {"nginx", {"nginx", LANG(nginx)}}, {"php", {"php", LANG(php)}}, {"query", {"query", LANG(query)}}, {"regex", {"regex", LANG(regex)}}, {"sql", {"sql", LANG(sql)}}, {"toml", {"toml", LANG(toml)}}, {"yaml", {"yaml", LANG(yaml)}}, {"cabal", {"cabal", LANG(cabal)}}, }; static const std::unordered_map kExtToLang = { {"sh", "bash"}, {"bash", "bash"}, {"c", "c"}, {"cpp", "cpp"}, {"cxx", "cpp"}, {"cc", "cpp"}, {"hpp", "h"}, {"hh", "h"}, {"hxx", "h"}, {"h", "h"}, {"css", "css"}, {"fish", "fish"}, {"go", "go"}, {"hs", "haskell"}, {"html", "html"}, {"htm", "html"}, {"js", "javascript"}, {"json", "json"}, {"lua", "lua"}, {"mk", "make"}, {"makefile", "make"}, {"py", "python"}, {"rb", "ruby"}, {"diff", "diff"}, {"erb", "embedded_template"}, {"etlua", "embedded_template"}, {"gd", "gdscript"}, {"gitattributes", "gitattributes"}, {"gitignore", "gitignore"}, {"mod", "gomod"}, {"ini", "ini"}, {"md", "markdown"}, {"markdown", "markdown"}, {"conf", "nginx"}, {"php", "php"}, {"scm", "query"}, {"regex", "regex"}, {"sql", "sql"}, {"toml", "toml"}, {"yaml", "yaml"}, {"yml", "yaml"}, {"cabal", "cabal"}, }; static const std::unordered_map kMimeToLang = { {"text/x-c", "c"}, {"text/x-c++", "cpp"}, {"text/x-shellscript", "bash"}, {"application/json", "json"}, {"text/javascript", "javascript"}, {"text/html", "html"}, {"text/css", "css"}, {"text/x-python", "python"}, {"text/x-ruby", "ruby"}, {"text/x-go", "go"}, {"text/x-haskell", "haskell"}, {"text/x-lua", "lua"}, {"text/x-diff", "diff"}, {"text/x-embedded-template", "embedded_template"}, {"text/x-gdscript", "gdscript"}, {"text/x-gitattributes", "gitattributes"}, {"text/x-gitignore", "gitignore"}, {"text/x-gomod", "gomod"}, {"text/x-ini", "ini"}, {"text/markdown", "markdown"}, {"text/x-nginx-conf", "nginx"}, {"application/x-php", "php"}, {"text/x-tree-sitter-query", "query"}, {"text/x-regex", "regex"}, {"text/x-sql", "sql"}, {"text/x-toml", "toml"}, {"text/x-yaml", "yaml"}, {"text/x-cabal", "cabal"}, }; #endif