rename command variable to *_adals_* instead of *_lsp_* and whole name to adals instead of adalsp

This commit is contained in:
Bartek thindil Jasicki 2019-10-18 18:26:08 +02:00
parent 8239b76c5a
commit 2f181658e6
5 changed files with 27 additions and 27 deletions

16
ale_linters/ada/adals.vim Normal file
View File

@ -0,0 +1,16 @@
" Author: Bartek Jasicki http://github.com/thindil
" Description: Support for Ada Language Server
call ale#Set('ada_adals_executable', 'ada_language_server')
function! ale_linters#ada#adals#GetRootDirectory(buffer) abort
return fnamemodify(bufname(a:buffer), ':p:h')
endfunction
call ale#linter#Define('ada', {
\ 'name': 'adals',
\ 'lsp': 'stdio',
\ 'executable': {b -> ale#Var(b, 'ada_adals_executable')},
\ 'command': '%e',
\ 'project_root': function('ale_linters#ada#adals#GetRootDirectory'),
\})

View File

@ -1,16 +0,0 @@
" Author: Bartek Jasicki http://github.com/thindil
" Description: Support for Ada Language Server
call ale#Set('ada_lsp_executable', 'ada_language_server')
function! ale_linters#ada#adalsp#GetRootDirectory(buffer) abort
return fnamemodify(bufname(a:buffer), ':p:h')
endfunction
call ale#linter#Define('ada', {
\ 'name': 'adalsp',
\ 'lsp': 'stdio',
\ 'executable': {b -> ale#Var(b, 'ada_lsp_executable')},
\ 'command': '%e',
\ 'project_root': function('ale_linters#ada#adalsp#GetRootDirectory'),
\})

View File

@ -35,8 +35,8 @@ g:ale_ada_gnatpp_options *g:ale_ada_gnatpp_options*
===============================================================================
ada-language-server *ale-ada-language-server*
g:ale_ada_lsp_executable *g:ale_ada_lsp_executable*
*b:ale_ada_lsp_executable*
g:ale_ada_adals_executable *g:ale_ada_adals_executable*
*b:ale_ada_adals_executable*
Type: |String|
Default: `'ada_language_server'`

View File

@ -0,0 +1,9 @@
Before:
call ale#assert#SetUpLinterTest('ada', 'adals')
After:
call ale#assert#TearDownLinterTest()
Execute(Sets adals executable):
let g:ale_ada_adals_executable = '/path/to /Ada'
AssertLinter '/path/to /Ada', ale#Escape('/path/to /Ada')

View File

@ -1,9 +0,0 @@
Before:
call ale#assert#SetUpLinterTest('ada', 'adalsp')
After:
call ale#assert#TearDownLinterTest()
Execute(Sets adalsp executable):
let g:ale_ada_lsp_executable = '/path/to /Ada'
AssertLinter '/path/to /Ada', ale#Escape('/path/to /Ada')