initial deploy of Vale linter
This commit is contained in:
parent
22324d9913
commit
c604d1f533
|
@ -0,0 +1,42 @@
|
|||
-- Do not load up plugin when in diff mode.
|
||||
if vim.opt.diff:get() then
|
||||
return
|
||||
end
|
||||
|
||||
local g = vim.g
|
||||
|
||||
g.ale_fixers = {
|
||||
css = { "prettier" },
|
||||
dart = { "dart-format" },
|
||||
fish = { "fish_indent" },
|
||||
javascript = { "prettier-standard" },
|
||||
json = { "prettier" },
|
||||
lua = { "stylua" },
|
||||
scss = { "prettier" },
|
||||
yml = { "prettier" },
|
||||
}
|
||||
|
||||
g.ale_linters = {
|
||||
eruby = {'erblint'},
|
||||
javascript = {'standard'},
|
||||
lua = { "selene" },
|
||||
json = { "jsonlint" },
|
||||
markdown = { "vale" },
|
||||
yaml = { "yamllint" },
|
||||
}
|
||||
|
||||
g.ale_completion_enabled = 0
|
||||
g.ale_echo_cursor = 0
|
||||
g.ale_fix_on_save = 0
|
||||
g.ale_hover_cursor = 0
|
||||
g.ale_lint_on_enter = 1
|
||||
g.ale_lint_on_filetype_changed = 0
|
||||
g.ale_lint_on_insert_leave = 1
|
||||
g.ale_lint_on_save = 1
|
||||
g.ale_lint_on_text_changed = "never"
|
||||
g.ale_linters_explicit = 1
|
||||
g.ale_maximum_file_size = 102400 -- 100KB
|
||||
g.ale_use_neovim_diagnostics_api = 1
|
||||
|
||||
-- ALE fix mapping.
|
||||
vim.api.nvim_set_keymap("n", "'f", "<Plug>(ale_fix)", { silent = true })
|
|
@ -0,0 +1,10 @@
|
|||
return {
|
||||
|
||||
{
|
||||
"dense-analysis/ale",
|
||||
config = function()
|
||||
require("config.ale")
|
||||
end,
|
||||
},
|
||||
|
||||
}
|
|
@ -0,0 +1,11 @@
|
|||
# This goes in a file named either `~/.vale.ini` or `_vale.ini`.
|
||||
StylesPath = styles
|
||||
MinAlertLevel = suggestion
|
||||
|
||||
# External packages
|
||||
Packages = Google, Readability, alex, proselint, write-good
|
||||
# Only Markdown and .txt files; change to whatever you're using.
|
||||
[*.{md,txt}]
|
||||
# List of styles to load.
|
||||
BasedOnStyles = alex, proselint, write-good
|
||||
|
Loading…
Reference in New Issue