mirror of https://github.com/dense-analysis/ale
Dhall fixes: use stdin, doc errors (#3868)
* purs-tidy * Dhall fixes: use stdin, docs errors
This commit is contained in:
parent
9264ffda23
commit
a099fe24b2
|
@ -3,12 +3,9 @@
|
|||
"
|
||||
function! ale#fixers#dhall_format#Fix(buffer) abort
|
||||
let l:executable = ale#dhall#GetExecutableWithOptions(a:buffer)
|
||||
let l:command = l:executable
|
||||
\ . ' format'
|
||||
\ . ' --inplace %t'
|
||||
|
||||
return {
|
||||
\ 'command': l:command,
|
||||
\ 'read_temporary_file': 1,
|
||||
\ 'command': l:executable
|
||||
\ . ' format'
|
||||
\}
|
||||
endfunction
|
||||
|
|
|
@ -1,18 +1,14 @@
|
|||
" Author: toastal <toastal@posteo.net>
|
||||
" Description: Dhall's package freezing
|
||||
" Description: Dhall’s package freezing
|
||||
|
||||
call ale#Set('dhall_freeze_options', '')
|
||||
|
||||
function! ale#fixers#dhall_freeze#Freeze(buffer) abort
|
||||
let l:executable = ale#dhall#GetExecutableWithOptions(a:buffer)
|
||||
let l:command = l:executable
|
||||
\ . ' freeze'
|
||||
\ . ale#Pad(ale#Var(a:buffer, 'dhall_freeze_options'))
|
||||
\ . ' --inplace %t'
|
||||
|
||||
|
||||
return {
|
||||
\ 'command': l:command,
|
||||
\ 'read_temporary_file': 1,
|
||||
\ 'command': l:executable
|
||||
\ . ' freeze'
|
||||
\ . ale#Pad(ale#Var(a:buffer, 'dhall_freeze_options'))
|
||||
\}
|
||||
endfunction
|
||||
|
|
|
@ -3,12 +3,9 @@
|
|||
|
||||
function! ale#fixers#dhall_lint#Fix(buffer) abort
|
||||
let l:executable = ale#dhall#GetExecutableWithOptions(a:buffer)
|
||||
let l:command = l:executable
|
||||
\ . ' lint'
|
||||
\ . ' --inplace %t'
|
||||
|
||||
return {
|
||||
\ 'command': l:command,
|
||||
\ 'read_temporary_file': 1,
|
||||
\ 'command': l:executable
|
||||
\ . ' lint'
|
||||
\}
|
||||
endfunction
|
||||
|
|
|
@ -6,15 +6,15 @@ g:ale_dhall_executable *g:ale_dhall_executable*
|
|||
Type: |String|
|
||||
Default: `'dhall'`
|
||||
|
||||
g:ale_dhall_options g:ale_dhall_options
|
||||
b:ale_dhall_options
|
||||
g:ale_dhall_options *g:ale_dhall_options*
|
||||
*b:ale_dhall_options*
|
||||
Type: |String|
|
||||
Default: `''`
|
||||
|
||||
This variable can be set to pass additional options to the 'dhall` executable.
|
||||
This is shared with `dhall-freeze` and `dhall-lint`.
|
||||
>
|
||||
let g:dhall_options = '--ascii'
|
||||
let g:ale_dhall_options = '--ascii'
|
||||
<
|
||||
|
||||
===============================================================================
|
||||
|
@ -30,15 +30,15 @@ dhall-freeze *ale-dhall-freeze*
|
|||
Dhall
|
||||
(https://dhall-lang.org/)
|
||||
|
||||
g:ale_dhall_freeze_options g:ale_dhall_freeze_options
|
||||
b:ale_dhall_freeze_options
|
||||
g:ale_dhall_freeze_options *g:ale_dhall_freeze_options*
|
||||
*b:ale_dhall_freeze_options*
|
||||
Type: |String|
|
||||
Default: `''`
|
||||
|
||||
This variable can be set to pass additional options to the 'dhall freeze`
|
||||
executable.
|
||||
>
|
||||
let g:dhall_freeze_options = '--all'
|
||||
let g:ale_dhall_freeze_options = '--all'
|
||||
<
|
||||
|
||||
===============================================================================
|
||||
|
|
|
@ -17,8 +17,6 @@ Execute(The dhall-format callback should return the correct options):
|
|||
AssertFixer
|
||||
\ {
|
||||
\ 'command': ale#Escape('odd-dhall')
|
||||
\ . ' --ascii'
|
||||
\ . ' format'
|
||||
\ . ' --inplace %t',
|
||||
\ 'read_temporary_file': 1,
|
||||
\ . ' --ascii'
|
||||
\ . ' format'
|
||||
\ }
|
||||
|
|
|
@ -16,9 +16,7 @@ Execute(The dhall-freeze callback should return the correct options):
|
|||
AssertFixer
|
||||
\ {
|
||||
\ 'command': ale#Escape('odd-dhall')
|
||||
\ . ' --ascii'
|
||||
\ . ' freeze'
|
||||
\ . ' --all'
|
||||
\ . ' --inplace %t',
|
||||
\ 'read_temporary_file': 1,
|
||||
\ . ' --ascii'
|
||||
\ . ' freeze'
|
||||
\ . ' --all'
|
||||
\ }
|
||||
|
|
|
@ -15,8 +15,6 @@ Execute(The dhall-lint callback should return the correct options):
|
|||
AssertFixer
|
||||
\ {
|
||||
\ 'command': ale#Escape('odd-dhall')
|
||||
\ . ' --ascii'
|
||||
\ . ' lint'
|
||||
\ . ' --inplace %t',
|
||||
\ 'read_temporary_file': 1,
|
||||
\ . ' --ascii'
|
||||
\ . ' lint'
|
||||
\ }
|
||||
|
|
Loading…
Reference in New Issue