mirror of
https://github.com/dense-analysis/ale.git
synced 2025-12-08 05:24:46 +08:00
Remove backwards compatibility with ancient setting names
This commit is contained in:
@@ -1,11 +1,6 @@
|
|||||||
" Author: w0rp <devw0rp@gmail.com>
|
" Author: w0rp <devw0rp@gmail.com>
|
||||||
" Description: Lints shell files by invoking the shell with -n
|
" Description: Lints shell files by invoking the shell with -n
|
||||||
|
|
||||||
" Backwards compatibility
|
|
||||||
if exists('g:ale_linters_sh_shell_default_shell')
|
|
||||||
let g:ale_sh_shell_default_shell = g:ale_linters_sh_shell_default_shell
|
|
||||||
endif
|
|
||||||
|
|
||||||
" This option can be changed to change the default shell when the shell
|
" This option can be changed to change the default shell when the shell
|
||||||
" cannot be taken from the hashbang line.
|
" cannot be taken from the hashbang line.
|
||||||
if !exists('g:ale_sh_shell_default_shell')
|
if !exists('g:ale_sh_shell_default_shell')
|
||||||
|
|||||||
@@ -102,7 +102,7 @@ function! ale#handlers#shellcheck#DefineLinter(filetype) abort
|
|||||||
" This global variable can be set with a string of comma-separated error
|
" This global variable can be set with a string of comma-separated error
|
||||||
" codes to exclude from shellcheck. For example:
|
" codes to exclude from shellcheck. For example:
|
||||||
" let g:ale_sh_shellcheck_exclusions = 'SC2002,SC2004'
|
" let g:ale_sh_shellcheck_exclusions = 'SC2002,SC2004'
|
||||||
call ale#Set('sh_shellcheck_exclusions', get(g:, 'ale_linters_sh_shellcheck_exclusions', ''))
|
call ale#Set('sh_shellcheck_exclusions', '')
|
||||||
call ale#Set('sh_shellcheck_executable', 'shellcheck')
|
call ale#Set('sh_shellcheck_executable', 'shellcheck')
|
||||||
call ale#Set('sh_shellcheck_dialect', 'auto')
|
call ale#Set('sh_shellcheck_dialect', 'auto')
|
||||||
call ale#Set('sh_shellcheck_options', '')
|
call ale#Set('sh_shellcheck_options', '')
|
||||||
|
|||||||
@@ -1,19 +0,0 @@
|
|||||||
" These tests, and the code that it covers, may be removed upon a major release.
|
|
||||||
|
|
||||||
After:
|
|
||||||
unlet! g:ale_linters_sh_shellcheck_exclusions
|
|
||||||
unlet! g:ale_sh_shellcheck_exclusions
|
|
||||||
unlet! g:ale_linters_sh_shell_default_shell
|
|
||||||
unlet! g:ale_sh_shell_default_shell
|
|
||||||
|
|
||||||
Execute(Old variable name for the 'shellcheck' linter should still work):
|
|
||||||
let g:ale_linters_sh_shellcheck_exclusions = 'SC1234'
|
|
||||||
runtime ale_linters/sh/shellcheck.vim
|
|
||||||
|
|
||||||
AssertEqual 'SC1234', g:ale_sh_shellcheck_exclusions
|
|
||||||
|
|
||||||
Execute (Old variable name for the 'shell' linter should still work):
|
|
||||||
let g:ale_linters_sh_shell_default_shell = 'woosh'
|
|
||||||
runtime ale_linters/sh/shell.vim
|
|
||||||
|
|
||||||
AssertEqual 'woosh', g:ale_sh_shell_default_shell
|
|
||||||
Reference in New Issue
Block a user