nvim: after/ftplugin/haskell: Lint on save
Now that we use static-ls as Haskell LSP which does not have hlint support for diagnostics yet, lint on save to get hlint diagnostics.
This commit is contained in:
parent
bd98551ec9
commit
cdde7294ff
1 changed files with 7 additions and 0 deletions
|
@ -4,3 +4,10 @@ local hls_config = lsp_utils.hls_config()
|
|||
vim.lsp.start(hls_config)
|
||||
|
||||
vim.bo.makeprg = 'cabal build --write-ghc-environment-files=always all'
|
||||
|
||||
vim.api.nvim_create_autocmd({ "BufWritePost" }, {
|
||||
buffer = 0,
|
||||
callback = function()
|
||||
require("lint").try_lint()
|
||||
end,
|
||||
})
|
||||
|
|
Loading…
Reference in a new issue