summaryrefslogtreecommitdiff
path: root/autoload/ale/fixers/hlint.vim
diff options
context:
space:
mode:
Diffstat (limited to 'autoload/ale/fixers/hlint.vim')
-rw-r--r--autoload/ale/fixers/hlint.vim13
1 files changed, 13 insertions, 0 deletions
diff --git a/autoload/ale/fixers/hlint.vim b/autoload/ale/fixers/hlint.vim
new file mode 100644
index 00000000..88779a55
--- /dev/null
+++ b/autoload/ale/fixers/hlint.vim
@@ -0,0 +1,13 @@
+" Author: eborden <evan@evan-borden.com>
+" Description: Integration of hlint refactor with ALE.
+"
+
+function! ale#fixers#hlint#Fix(buffer) abort
+ return {
+ \ 'command': ale#handlers#hlint#GetExecutable(a:buffer)
+ \ . ' --refactor'
+ \ . ' --refactor-options="--inplace"'
+ \ . ' %t',
+ \ 'read_temporary_file': 1,
+ \}
+endfunction