summaryrefslogtreecommitdiff
path: root/lua/getchoo/efmls.lua
blob: 92d61e9151e4f1ca0113aacce2f5b01a92b79966 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
local alex = require("efmls-configs.linters.alex")
alex.rootMarkers = nil
local actionlint = require("efmls-configs.linters.actionlint")
local beautysh = require("efmls-configs.formatters.beautysh")
local fish_indent = require("efmls-configs.formatters.fish_indent")
local prettier = require("efmls-configs.formatters.prettier")
local prettier_eslint = require("efmls-configs.formatters.prettier_eslint")
local selene = require("efmls-configs.linters.selene")
local statix = require("efmls-configs.linters.statix")
local stylua = require("efmls-configs.formatters.stylua")

local languages = {
	all = { alex },

	bash = {
		beautysh,
	},

	css = { prettier },

	fish = { fish_indent },

	html = { prettier },

	javascript = { prettier_eslint },

	json = { prettier },

	lua = { selene, stylua },

	nix = { statix },

	sass = { prettier },

	scss = { prettier },

	sh = { beautysh },

	typescript = { prettier_eslint },

	yaml = { prettier, actionlint },

	zsh = { beautysh },
}

return {
	filetypes = vim.tbl_keys(languages),

	settings = {
		rootMarkers = { ".git/" },
		languages = languages,
	},

	init_options = {
		documentFormatting = true,
		documentRangeFormatting = true,
	},
}