default-config.lua 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908
  1. CONFIG_PATH = os.getenv "HOME" .. "/.local/share/lunarvim/lvim"
  2. DATA_PATH = vim.fn.stdpath "data"
  3. CACHE_PATH = vim.fn.stdpath "cache"
  4. TERMINAL = vim.fn.expand "$TERMINAL"
  5. USER = vim.fn.expand "$USER"
  6. lvim = {
  7. leader = "space",
  8. colorscheme = "spacegray",
  9. line_wrap_cursor_movement = true,
  10. transparent_window = false,
  11. format_on_save = true,
  12. vsnip_dir = os.getenv "HOME" .. "/.config/snippets",
  13. database = { save_location = "~/.config/lunarvim_db", auto_execute = 1 },
  14. keys = {},
  15. -- TODO why do we need this?
  16. builtin = {
  17. lspinstall = {},
  18. telescope = {},
  19. compe = {},
  20. autopairs = {},
  21. treesitter = {},
  22. nvimtree = {},
  23. gitsigns = {},
  24. which_key = {},
  25. comment = {},
  26. rooter = {},
  27. galaxyline = {},
  28. bufferline = {},
  29. dap = {},
  30. dashboard = {},
  31. terminal = {},
  32. },
  33. lsp = {
  34. diagnostics = {
  35. virtual_text = {
  36. prefix = "",
  37. spacing = 0,
  38. },
  39. signs = true,
  40. underline = true,
  41. },
  42. override = {},
  43. document_highlight = true,
  44. popup_border = "single",
  45. default_keybinds = true,
  46. on_attach_callback = nil,
  47. },
  48. plugins = {
  49. -- use lv-config.lua for this not put here
  50. },
  51. autocommands = {},
  52. }
  53. local schemas = nil
  54. local common_on_attach = require("lsp").common_on_attach
  55. local common_capabilities = require("lsp").common_capabilities()
  56. local status_ok, jsonls_settings = pcall(require, "nlspsettings.jsonls")
  57. if status_ok then
  58. schemas = jsonls_settings.get_default_schemas()
  59. end
  60. -- TODO move all of this into lang specific files, only require when using
  61. lvim.lang = {
  62. c = {
  63. formatter = {
  64. exe = "clang_format",
  65. args = {},
  66. stdin = true,
  67. },
  68. linters = {
  69. "clangtidy",
  70. },
  71. lsp = {
  72. provider = "clangd",
  73. setup = {
  74. cmd = {
  75. DATA_PATH .. "/lspinstall/cpp/clangd/bin/clangd",
  76. "--background-index",
  77. "--header-insertion=never",
  78. "--cross-file-rename",
  79. "--clang-tidy",
  80. "--clang-tidy-checks=-*,llvm-*,clang-analyzer-*",
  81. },
  82. on_attach = common_on_attach,
  83. capabilities = common_capabilities,
  84. },
  85. },
  86. },
  87. cpp = {
  88. formatter = {
  89. exe = "clang_format",
  90. args = {},
  91. stdin = true,
  92. },
  93. linters = {
  94. "cppcheck",
  95. "clangtidy",
  96. },
  97. lsp = {
  98. provider = "clangd",
  99. setup = {
  100. cmd = {
  101. DATA_PATH .. "/lspinstall/cpp/clangd/bin/clangd",
  102. "--background-index",
  103. "--header-insertion=never",
  104. "--cross-file-rename",
  105. "--clang-tidy",
  106. "--clang-tidy-checks=-*,llvm-*,clang-analyzer-*",
  107. },
  108. on_attach = common_on_attach,
  109. capabilities = common_capabilities,
  110. },
  111. },
  112. },
  113. cs = {
  114. formatter = {
  115. exe = "",
  116. args = {},
  117. },
  118. linters = {},
  119. lsp = {
  120. provider = "omnisharp",
  121. setup = {
  122. cmd = {
  123. DATA_PATH .. "/lspinstall/csharp/omnisharp/run",
  124. "--stdio",
  125. },
  126. on_attach = common_on_attach,
  127. capabilities = common_capabilities,
  128. },
  129. },
  130. },
  131. cmake = {
  132. formatter = {
  133. exe = "clang_format",
  134. args = {},
  135. },
  136. linters = {},
  137. lsp = {
  138. provider = "cmake",
  139. setup = {
  140. cmd = {
  141. DATA_PATH .. "/lspinstall/cmake/venv/bin/cmake-language-server",
  142. "--stdio",
  143. },
  144. on_attach = common_on_attach,
  145. capabilities = common_capabilities,
  146. },
  147. },
  148. },
  149. clojure = {
  150. formatter = {
  151. exe = "",
  152. args = {},
  153. },
  154. linters = {},
  155. lsp = {
  156. provider = "clojure_lsp",
  157. setup = {
  158. cmd = {
  159. DATA_PATH .. "/lspinstall/clojure/clojure-lsp",
  160. "--stdio",
  161. },
  162. on_attach = common_on_attach,
  163. capabilities = common_capabilities,
  164. },
  165. },
  166. },
  167. css = {
  168. formatter = {
  169. exe = "prettier",
  170. args = {},
  171. },
  172. linters = {},
  173. lsp = {
  174. provider = "cssls",
  175. setup = {
  176. cmd = {
  177. "node",
  178. DATA_PATH .. "/lspinstall/css/vscode-css/css-language-features/server/dist/node/cssServerMain.js",
  179. "--stdio",
  180. },
  181. on_attach = common_on_attach,
  182. capabilities = common_capabilities,
  183. },
  184. },
  185. },
  186. dart = {
  187. formatter = {
  188. exe = "dart",
  189. args = { "format" },
  190. stdin = true,
  191. },
  192. linters = {},
  193. lsp = {
  194. provider = "dartls",
  195. setup = {
  196. cmd = {
  197. "dart",
  198. "/usr/lib/dart/bin/snapshots/analysis_server.dart.snapshot",
  199. "--lsp",
  200. },
  201. on_attach = common_on_attach,
  202. capabilities = common_capabilities,
  203. },
  204. },
  205. },
  206. docker = {
  207. formatter = {
  208. exe = "",
  209. args = {},
  210. },
  211. linters = {},
  212. lsp = {
  213. provider = "dockerls",
  214. setup = {
  215. cmd = {
  216. DATA_PATH .. "/lspinstall/dockerfile/node_modules/.bin/docker-langserver",
  217. "--stdio",
  218. },
  219. on_attach = common_on_attach,
  220. capabilities = common_capabilities,
  221. },
  222. },
  223. },
  224. elixir = {
  225. formatter = {
  226. exe = "mix",
  227. args = { "format" },
  228. stdin = true,
  229. },
  230. linters = {},
  231. lsp = {
  232. provider = "elixirls",
  233. setup = {
  234. cmd = {
  235. DATA_PATH .. "/lspinstall/elixir/elixir-ls/language_server.sh",
  236. },
  237. on_attach = common_on_attach,
  238. capabilities = common_capabilities,
  239. },
  240. },
  241. },
  242. elm = {
  243. formatter = {
  244. exe = "",
  245. args = {},
  246. stdin = true,
  247. },
  248. linters = {},
  249. lsp = {
  250. provider = "elmls",
  251. setup = {
  252. cmd = {
  253. DATA_PATH .. "/lspinstall/elm/node_modules/.bin/elm-language-server",
  254. },
  255. on_attach = common_on_attach,
  256. init_options = {
  257. elmAnalyseTrigger = "change",
  258. elmFormatPath = DATA_PATH .. "/lspinstall/elm/node_modules/.bin/elm-format",
  259. elmPath = DATA_PATH .. "/lspinstall/elm/node_modules/.bin/",
  260. elmTestPath = DATA_PATH .. "/lspinstall/elm/node_modules/.bin/elm-test",
  261. },
  262. },
  263. },
  264. },
  265. erlang = {
  266. formatter = {
  267. exe = "",
  268. args = {},
  269. },
  270. linters = {},
  271. lsp = {
  272. provider = "erlangls",
  273. setup = {
  274. cmd = {
  275. "erlang_ls",
  276. },
  277. on_attach = common_on_attach,
  278. capabilities = common_capabilities,
  279. },
  280. },
  281. },
  282. emmet = { active = false },
  283. fish = {
  284. formatter = {
  285. exe = "",
  286. args = {},
  287. },
  288. linters = {},
  289. lsp = {
  290. provider = "",
  291. setup = {
  292. on_attach = common_on_attach,
  293. capabilities = common_capabilities,
  294. },
  295. },
  296. },
  297. go = {
  298. formatter = {
  299. exe = "gofmt",
  300. args = {},
  301. stdin = true,
  302. },
  303. linters = {
  304. "golangcilint",
  305. "revive",
  306. },
  307. lsp = {
  308. provider = "gopls",
  309. setup = {
  310. cmd = {
  311. DATA_PATH .. "/lspinstall/go/gopls",
  312. },
  313. on_attach = common_on_attach,
  314. capabilities = common_capabilities,
  315. },
  316. },
  317. },
  318. graphql = {
  319. formatter = {
  320. exe = "",
  321. args = {},
  322. },
  323. linters = {},
  324. lsp = {
  325. provider = "graphql",
  326. setup = {
  327. cmd = {
  328. "graphql-lsp",
  329. "server",
  330. "-m",
  331. "stream",
  332. },
  333. on_attach = common_on_attach,
  334. capabilities = common_capabilities,
  335. },
  336. },
  337. },
  338. html = {
  339. formatter = {
  340. exe = "prettier",
  341. args = {},
  342. },
  343. linters = {
  344. "tidy",
  345. -- https://docs.errata.ai/vale/scoping#html
  346. "vale",
  347. },
  348. lsp = {
  349. provider = "html",
  350. setup = {
  351. cmd = {
  352. "node",
  353. DATA_PATH .. "/lspinstall/html/vscode-html/html-language-features/server/dist/node/htmlServerMain.js",
  354. "--stdio",
  355. },
  356. on_attach = common_on_attach,
  357. capabilities = common_capabilities,
  358. },
  359. },
  360. },
  361. java = {
  362. formatter = {
  363. exe = "prettier",
  364. args = { "--stdin-filepath", vim.api.nvim_buf_get_name(0) },
  365. },
  366. linters = {},
  367. lsp = {
  368. provider = "jdtls",
  369. setup = {
  370. cmd = { DATA_PATH .. "/lspinstall/java/jdtls.sh" },
  371. on_attach = common_on_attach,
  372. capabilities = common_capabilities,
  373. },
  374. },
  375. },
  376. json = {
  377. formatter = {
  378. exe = "python",
  379. args = { "-m", "json.tool" },
  380. stdin = true,
  381. },
  382. linters = {},
  383. lsp = {
  384. provider = "jsonls",
  385. setup = {
  386. cmd = {
  387. "node",
  388. DATA_PATH .. "/lspinstall/json/vscode-json/json-language-features/server/dist/node/jsonServerMain.js",
  389. "--stdio",
  390. },
  391. on_attach = common_on_attach,
  392. capabilities = common_capabilities,
  393. settings = {
  394. json = {
  395. schemas = schemas,
  396. -- = {
  397. -- {
  398. -- fileMatch = { "package.json" },
  399. -- url = "https://json.schemastore.org/package.json",
  400. -- },
  401. -- },
  402. },
  403. },
  404. commands = {
  405. Format = {
  406. function()
  407. vim.lsp.buf.range_formatting({}, { 0, 0 }, { vim.fn.line "$", 0 })
  408. end,
  409. },
  410. },
  411. },
  412. },
  413. },
  414. julia = {
  415. formatter = {
  416. exe = "",
  417. args = {},
  418. },
  419. linters = {},
  420. lsp = {
  421. provider = "julials",
  422. setup = {
  423. {
  424. "julia",
  425. "--startup-file=no",
  426. "--history-file=no",
  427. -- vim.fn.expand "~/.config/nvim/lua/lsp/julia/run.jl",
  428. CONFIG_PATH .. "/utils/julia/run.jl",
  429. },
  430. on_attach = common_on_attach,
  431. capabilities = common_capabilities,
  432. },
  433. },
  434. },
  435. kotlin = {
  436. formatter = {
  437. exe = "",
  438. args = {},
  439. },
  440. linters = {},
  441. lsp = {
  442. provider = "kotlin_language_server",
  443. setup = {
  444. cmd = {
  445. DATA_PATH .. "/lspinstall/kotlin/server/bin/kotlin-language-server",
  446. },
  447. on_attach = common_on_attach,
  448. root_dir = function(fname)
  449. local util = require "lspconfig/util"
  450. local root_files = {
  451. "settings.gradle", -- Gradle (multi-project)
  452. "settings.gradle.kts", -- Gradle (multi-project)
  453. "build.xml", -- Ant
  454. "pom.xml", -- Maven
  455. }
  456. local fallback_root_files = {
  457. "build.gradle", -- Gradle
  458. "build.gradle.kts", -- Gradle
  459. }
  460. return util.root_pattern(unpack(root_files))(fname) or util.root_pattern(unpack(fallback_root_files))(fname)
  461. end,
  462. },
  463. },
  464. },
  465. lua = {
  466. formatter = {
  467. exe = "stylua",
  468. args = {},
  469. },
  470. linters = { "luacheck" },
  471. lsp = {
  472. provider = "sumneko_lua",
  473. setup = {
  474. cmd = {
  475. DATA_PATH .. "/lspinstall/lua/sumneko-lua-language-server",
  476. "-E",
  477. DATA_PATH .. "/lspinstall/lua/main.lua",
  478. },
  479. on_attach = common_on_attach,
  480. settings = {
  481. Lua = {
  482. runtime = {
  483. -- Tell the language server which version of Lua you're using (most likely LuaJIT in the case of Neovim)
  484. version = "LuaJIT",
  485. -- Setup your lua path
  486. path = vim.split(package.path, ";"),
  487. },
  488. diagnostics = {
  489. -- Get the language server to recognize the `vim` global
  490. globals = { "vim", "lvim" },
  491. },
  492. workspace = {
  493. -- Make the server aware of Neovim runtime files
  494. library = {
  495. [vim.fn.expand "~/.local/share/lunarvim/lvim/lua"] = true,
  496. [vim.fn.expand "$VIMRUNTIME/lua"] = true,
  497. [vim.fn.expand "$VIMRUNTIME/lua/vim/lsp"] = true,
  498. },
  499. maxPreload = 100000,
  500. preloadFileSize = 1000,
  501. },
  502. },
  503. },
  504. },
  505. },
  506. },
  507. php = {
  508. formatter = {
  509. exe = "phpcbf",
  510. args = { "--standard=PSR12", vim.api.nvim_buf_get_name(0) },
  511. },
  512. linters = {},
  513. lsp = {
  514. provider = "intelephense",
  515. setup = {
  516. cmd = {
  517. DATA_PATH .. "/lspinstall/php/node_modules/.bin/intelephense",
  518. "--stdio",
  519. },
  520. on_attach = common_on_attach,
  521. filetypes = { "php", "phtml" },
  522. settings = {
  523. intelephense = {
  524. environment = {
  525. phpVersion = "7.4",
  526. },
  527. },
  528. },
  529. },
  530. },
  531. },
  532. javascript = {
  533. -- @usage can be prettier or eslint
  534. formatter = {
  535. exe = "prettier",
  536. args = {},
  537. },
  538. linters = {
  539. "eslint",
  540. },
  541. lsp = {
  542. provider = "tsserver",
  543. setup = {
  544. cmd = {
  545. -- TODO:
  546. DATA_PATH .. "/lspinstall/typescript/node_modules/.bin/typescript-language-server",
  547. "--stdio",
  548. },
  549. on_attach = require("lsp").common_on_attach,
  550. capabilities = require("lsp").common_capabilities(),
  551. },
  552. },
  553. },
  554. javascriptreact = {
  555. -- @usage can be prettier or eslint
  556. formatter = {
  557. exe = "prettier",
  558. args = {},
  559. },
  560. linters = {
  561. "eslint",
  562. },
  563. lsp = {
  564. provider = "tsserver",
  565. setup = {
  566. cmd = {
  567. -- TODO:
  568. DATA_PATH .. "/lspinstall/typescript/node_modules/.bin/typescript-language-server",
  569. "--stdio",
  570. },
  571. on_attach = require("lsp").common_on_attach,
  572. capabilities = require("lsp").common_capabilities(),
  573. },
  574. },
  575. },
  576. python = {
  577. -- @usage can be flake8 or yapf
  578. formatter = {
  579. exe = "black",
  580. args = {},
  581. },
  582. linters = {
  583. "flake8",
  584. "pylint",
  585. "mypy",
  586. },
  587. lsp = {
  588. provider = "pyright",
  589. setup = {
  590. cmd = {
  591. DATA_PATH .. "/lspinstall/python/node_modules/.bin/pyright-langserver",
  592. "--stdio",
  593. },
  594. on_attach = common_on_attach,
  595. capabilities = common_capabilities,
  596. },
  597. },
  598. },
  599. -- R -e 'install.packages("formatR",repos = "http://cran.us.r-project.org")'
  600. -- R -e 'install.packages("readr",repos = "http://cran.us.r-project.org")'
  601. r = {
  602. formatter = {
  603. exe = "",
  604. args = {},
  605. },
  606. linters = {},
  607. lsp = {
  608. provider = "r_language_server",
  609. setup = {
  610. cmd = {
  611. "R",
  612. "--slave",
  613. "-e",
  614. "languageserver::run()",
  615. },
  616. on_attach = common_on_attach,
  617. capabilities = common_capabilities,
  618. },
  619. },
  620. },
  621. ruby = {
  622. formatter = {
  623. exe = "rufo",
  624. args = {},
  625. },
  626. linters = { "ruby" },
  627. lsp = {
  628. provider = "solargraph",
  629. setup = {
  630. cmd = {
  631. DATA_PATH .. "/lspinstall/ruby/solargraph/solargraph",
  632. "stdio",
  633. },
  634. on_attach = common_on_attach,
  635. capabilities = common_capabilities,
  636. },
  637. },
  638. },
  639. rust = {
  640. formatter = {
  641. exe = "",
  642. args = {},
  643. },
  644. linters = {},
  645. lsp = {
  646. provider = "rust_analyzer",
  647. setup = {
  648. cmd = {
  649. DATA_PATH .. "/lspinstall/rust/rust-analyzer",
  650. },
  651. on_attach = common_on_attach,
  652. capabilities = common_capabilities,
  653. },
  654. },
  655. },
  656. scala = {
  657. formatter = {
  658. exe = "",
  659. args = {},
  660. },
  661. linters = { "" },
  662. lsp = {
  663. provider = "metals",
  664. setup = {
  665. on_attach = common_on_attach,
  666. capabilities = common_capabilities,
  667. },
  668. },
  669. },
  670. sh = {
  671. -- @usage can be 'shfmt'
  672. formatter = {
  673. exe = "shfmt",
  674. args = {},
  675. },
  676. -- @usage can be 'shellcheck'
  677. linters = { "shellcheck" },
  678. lsp = {
  679. provider = "bashls",
  680. setup = {
  681. cmd = {
  682. DATA_PATH .. "/lspinstall/bash/node_modules/.bin/bash-language-server",
  683. "start",
  684. },
  685. on_attach = common_on_attach,
  686. capabilities = common_capabilities,
  687. },
  688. },
  689. },
  690. svelte = {
  691. formatter = {
  692. exe = "",
  693. args = {},
  694. },
  695. linters = {},
  696. lsp = {
  697. provider = "svelte",
  698. setup = {
  699. cmd = {
  700. DATA_PATH .. "/lspinstall/svelte/node_modules/.bin/svelteserver",
  701. "--stdio",
  702. },
  703. on_attach = common_on_attach,
  704. capabilities = common_capabilities,
  705. },
  706. },
  707. },
  708. swift = {
  709. formatter = {
  710. exe = "swiftformat",
  711. args = {},
  712. },
  713. linters = {},
  714. lsp = {
  715. provider = "sourcekit",
  716. setup = {
  717. cmd = {
  718. "xcrun",
  719. "sourcekit-lsp",
  720. },
  721. on_attach = common_on_attach,
  722. capabilities = common_capabilities,
  723. },
  724. },
  725. },
  726. tailwindcss = {
  727. active = false,
  728. filetypes = {
  729. "html",
  730. "css",
  731. "scss",
  732. "javascript",
  733. "javascriptreact",
  734. "typescript",
  735. "typescriptreact",
  736. },
  737. },
  738. terraform = {
  739. formatter = {
  740. exe = "",
  741. args = {},
  742. stdin = false,
  743. },
  744. linters = {},
  745. lsp = {
  746. provider = "terraformls",
  747. setup = {
  748. cmd = {
  749. DATA_PATH .. "/lspinstall/terraform/terraform-ls",
  750. "serve",
  751. },
  752. on_attach = common_on_attach,
  753. capabilities = common_capabilities,
  754. },
  755. },
  756. },
  757. tex = {
  758. formatter = {
  759. exe = "latexindent",
  760. args = {},
  761. stdin = false,
  762. },
  763. linters = { "chktex" },
  764. lsp = {
  765. provider = "texlab",
  766. setup = {
  767. cmd = { DATA_PATH .. "/lspinstall/latex/texlab" },
  768. on_attach = common_on_attach,
  769. capabilities = common_capabilities,
  770. },
  771. },
  772. },
  773. typescript = {
  774. -- @usage can be prettier or eslint
  775. formatter = {
  776. exe = "prettier",
  777. args = {},
  778. },
  779. linters = {
  780. "eslint",
  781. },
  782. lsp = {
  783. provider = "tsserver",
  784. setup = {
  785. cmd = {
  786. -- TODO:
  787. DATA_PATH .. "/lspinstall/typescript/node_modules/.bin/typescript-language-server",
  788. "--stdio",
  789. },
  790. on_attach = require("lsp").common_on_attach,
  791. capabilities = require("lsp").common_capabilities(),
  792. },
  793. },
  794. },
  795. typescriptreact = {
  796. -- @usage can be prettier or eslint
  797. formatter = {
  798. exe = "prettier",
  799. args = {},
  800. },
  801. linters = {
  802. "eslint",
  803. },
  804. lsp = {
  805. provider = "tsserver",
  806. setup = {
  807. cmd = {
  808. -- TODO:
  809. DATA_PATH .. "/lspinstall/typescript/node_modules/.bin/typescript-language-server",
  810. "--stdio",
  811. },
  812. on_attach = require("lsp").common_on_attach,
  813. capabilities = require("lsp").common_capabilities(),
  814. },
  815. },
  816. },
  817. vim = {
  818. formatter = {
  819. exe = "",
  820. args = {},
  821. },
  822. linters = { "" },
  823. lsp = {
  824. provider = "vimls",
  825. setup = {
  826. cmd = {
  827. DATA_PATH .. "/lspinstall/vim/node_modules/.bin/vim-language-server",
  828. "--stdio",
  829. },
  830. on_attach = common_on_attach,
  831. capabilities = common_capabilities,
  832. },
  833. },
  834. },
  835. vue = {
  836. formatter = {
  837. exe = "prettier",
  838. args = {},
  839. },
  840. linters = {},
  841. lsp = {
  842. provider = "vetur",
  843. setup = {
  844. cmd = {
  845. DATA_PATH .. "/lspinstall/vue/node_modules/.bin/vls",
  846. },
  847. on_attach = common_on_attach,
  848. capabilities = common_capabilities,
  849. },
  850. },
  851. },
  852. yaml = {
  853. formatter = {
  854. exe = "prettier",
  855. args = {},
  856. },
  857. linters = {},
  858. lsp = {
  859. provider = "yamlls",
  860. setup = {
  861. cmd = {
  862. DATA_PATH .. "/lspinstall/yaml/node_modules/.bin/yaml-language-server",
  863. "--stdio",
  864. },
  865. on_attach = common_on_attach,
  866. capabilities = common_capabilities,
  867. },
  868. },
  869. },
  870. zig = {
  871. formatter = {
  872. exe = "",
  873. args = {},
  874. stdin = false,
  875. },
  876. linters = {},
  877. lsp = {
  878. provider = "zls",
  879. setup = {
  880. cmd = {
  881. "zls",
  882. },
  883. on_attach = common_on_attach,
  884. capabilities = common_capabilities,
  885. },
  886. },
  887. },
  888. }
  889. require("core.which-key").config()
  890. require "core.status_colors"
  891. require("core.gitsigns").config()
  892. require("core.compe").config()
  893. require("core.dashboard").config()
  894. require("core.dap").config()
  895. require("core.terminal").config()
  896. require("core.telescope").config()
  897. require("core.treesitter").config()
  898. require("core.nvimtree").config()