nvim/lua/my-lint.lua
2022-10-28 20:55:05 +02:00

18 lines
377 B
Lua

require('lint').linters_by_ft = {
python = {'flake8', 'pylint', 'pycodestyle', 'pydocstyle',},
php = {'phpcs'},
markdown = {'markdownlint'}
}
vim.api.nvim_create_autocmd({ "BufWritePost" }, {
callback = function()
require("lint").try_lint()
end,
})
vim.api.nvim_create_autocmd({ "BufEnter" }, {
callback = function()
require("lint").try_lint()
end,
})