mirror of
https://github.com/dense-analysis/ale
synced 2024-12-20 05:11:26 +00:00
ab0bf61512
This commit add support for ink-language-server, which it does by largely copying and pasting from the pure-language-server PR that was merged recently. The most interesting things to note are: - ink-language-server is distributed upstream via npm, which is why we search through node_modules - With some coaxing, it can be installed globally - which is why we search for a global binary. - Ink is a funky language, and users will likely need to add initialization options. - I am not incredibly familiar with vimscript; and I may not have done some of the buffer searching correctly.
23 lines
675 B
Plaintext
23 lines
675 B
Plaintext
Before:
|
|
call ale#assert#SetUpLinterTest('ink', 'ls')
|
|
set ft=ink
|
|
|
|
After:
|
|
call ale#assert#TearDownLinterTest()
|
|
|
|
Execute(should set correct defaults):
|
|
AssertLinter 'ink-language-server', ale#Escape('ink-language-server') . ' --stdio'
|
|
|
|
Execute(should set correct LSP values):
|
|
call ale#test#SetFilename('ink_paths/story/main.ink')
|
|
|
|
AssertLSPLanguage 'ink'
|
|
AssertLSPOptions {}
|
|
AssertLSPConfig {}
|
|
AssertLSPProject ale#path#Simplify(g:dir . '/ink_paths/story')
|
|
|
|
Execute(should accept configuration settings):
|
|
AssertLSPConfig {}
|
|
let b:ale_ink_ls_initialization_options = {'ink': {'runThroughMono': v:true}}
|
|
AssertLSPOptions {'ink': {'runThroughMono': v:true}}
|