mirror of
https://github.com/dense-analysis/ale.git
synced 2025-12-09 22:14:44 +08:00
Add support for ink-language-server
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.
This commit is contained in:
22
test/command_callback/test_ink_ls_command_callbacks.vader
Normal file
22
test/command_callback/test_ink_ls_command_callbacks.vader
Normal file
@@ -0,0 +1,22 @@
|
||||
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}}
|
||||
Reference in New Issue
Block a user