forked from github-mirrors/ale
VSCode LSPs for CSS, HTML and JSON (#4175)
Switched to `vscode-langservers-extracted` as it is the one most up-to-date.
This commit is contained in:
parent
34892186e4
commit
56399106fc
|
@ -0,0 +1,16 @@
|
||||||
|
" Author: Dalius Dobravolskas <dalius.dobravolskas@gmail.com>
|
||||||
|
" Description: VSCode css language server
|
||||||
|
|
||||||
|
function! ale_linters#css#vscodecss#GetProjectRoot(buffer) abort
|
||||||
|
let l:git_path = ale#path#FindNearestDirectory(a:buffer, '.git')
|
||||||
|
|
||||||
|
return !empty(l:git_path) ? fnamemodify(l:git_path, ':h:h') : ''
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
call ale#linter#Define('css', {
|
||||||
|
\ 'name': 'vscodecss',
|
||||||
|
\ 'lsp': 'stdio',
|
||||||
|
\ 'executable': 'vscode-css-language-server',
|
||||||
|
\ 'command': '%e --stdio',
|
||||||
|
\ 'project_root': function('ale_linters#css#vscodecss#GetProjectRoot'),
|
||||||
|
\})
|
|
@ -0,0 +1,16 @@
|
||||||
|
" Author: Dalius Dobravolskas <dalius.dobravolskas@gmail.com>
|
||||||
|
" Description: VSCode html language server
|
||||||
|
|
||||||
|
function! ale_linters#html#vscodehtml#GetProjectRoot(buffer) abort
|
||||||
|
let l:git_path = ale#path#FindNearestDirectory(a:buffer, '.git')
|
||||||
|
|
||||||
|
return !empty(l:git_path) ? fnamemodify(l:git_path, ':h:h') : ''
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
call ale#linter#Define('html', {
|
||||||
|
\ 'name': 'vscodehtml',
|
||||||
|
\ 'lsp': 'stdio',
|
||||||
|
\ 'executable': 'vscode-html-language-server',
|
||||||
|
\ 'command': '%e --stdio',
|
||||||
|
\ 'project_root': function('ale_linters#html#vscodehtml#GetProjectRoot'),
|
||||||
|
\})
|
|
@ -1,5 +1,5 @@
|
||||||
" Author: Dalius Dobravolskas <dalius.dobravolskas@gmail.com>
|
" Author: Dalius Dobravolskas <dalius.dobravolskas@gmail.com>
|
||||||
" Description: VSCode json languageserver
|
" Description: VSCode json language server
|
||||||
|
|
||||||
function! ale_linters#json#vscodejson#GetProjectRoot(buffer) abort
|
function! ale_linters#json#vscodejson#GetProjectRoot(buffer) abort
|
||||||
let l:git_path = ale#path#FindNearestDirectory(a:buffer, '.git')
|
let l:git_path = ale#path#FindNearestDirectory(a:buffer, '.git')
|
||||||
|
@ -10,7 +10,7 @@ endfunction
|
||||||
call ale#linter#Define('json', {
|
call ale#linter#Define('json', {
|
||||||
\ 'name': 'vscodejson',
|
\ 'name': 'vscodejson',
|
||||||
\ 'lsp': 'stdio',
|
\ 'lsp': 'stdio',
|
||||||
\ 'executable': 'vscode-json-languageserver',
|
\ 'executable': 'vscode-json-language-server',
|
||||||
\ 'command': '%e --stdio',
|
\ 'command': '%e --stdio',
|
||||||
\ 'project_root': function('ale_linters#json#vscodejson#GetProjectRoot'),
|
\ 'project_root': function('ale_linters#json#vscodejson#GetProjectRoot'),
|
||||||
\})
|
\})
|
||||||
|
|
|
@ -49,5 +49,18 @@ g:ale_css_stylelint_use_global *g:ale_css_stylelint_use_global*
|
||||||
See |ale-integrations-local-executables|
|
See |ale-integrations-local-executables|
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
vscodecss *ale-css-vscode*
|
||||||
|
|
||||||
|
Website: https://github.com/hrsh7th/vscode-langservers-extracted
|
||||||
|
|
||||||
|
Installation
|
||||||
|
-------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
Install VSCode css language server either globally or locally: >
|
||||||
|
|
||||||
|
npm install -g vscode-langservers-extracted
|
||||||
|
<
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|
||||||
|
|
|
@ -164,6 +164,19 @@ g:ale_html_tidy_use_global *g:html_tidy_use_global*
|
||||||
See |ale-integrations-local-executables|
|
See |ale-integrations-local-executables|
|
||||||
|
|
||||||
|
|
||||||
|
===============================================================================
|
||||||
|
vscodehtml *ale-html-vscode*
|
||||||
|
|
||||||
|
Website: https://github.com/hrsh7th/vscode-langservers-extracted
|
||||||
|
|
||||||
|
Installation
|
||||||
|
-------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
Install VSCode html language server either globally or locally: >
|
||||||
|
|
||||||
|
npm install -g vscode-langservers-extracted
|
||||||
|
<
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
write-good *ale-html-write-good*
|
write-good *ale-html-write-good*
|
||||||
|
|
||||||
|
|
|
@ -156,14 +156,14 @@ g:ale_json_spectral_use_global *g:ale_json_spectral_use_global*
|
||||||
===============================================================================
|
===============================================================================
|
||||||
vscodejson *ale-json-vscode*
|
vscodejson *ale-json-vscode*
|
||||||
|
|
||||||
Website: https://www.npmjs.com/package/vscode-json-languageserver
|
Website: https://github.com/hrsh7th/vscode-langservers-extracted
|
||||||
|
|
||||||
Installation
|
Installation
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
|
|
||||||
Install VSCode json language server either globally or locally: >
|
Install VSCode json language server either globally or locally: >
|
||||||
|
|
||||||
npm install -g vscode-json-languageserver
|
npm install -g vscode-langservers-extracted
|
||||||
<
|
<
|
||||||
|
|
||||||
===============================================================================
|
===============================================================================
|
||||||
|
|
|
@ -114,6 +114,7 @@ Notes:
|
||||||
* `ameba`!!
|
* `ameba`!!
|
||||||
* `crystal`!!
|
* `crystal`!!
|
||||||
* CSS
|
* CSS
|
||||||
|
* `VSCode CSS language server`
|
||||||
* `cspell`
|
* `cspell`
|
||||||
* `csslint`
|
* `csslint`
|
||||||
* `fecs`
|
* `fecs`
|
||||||
|
@ -240,6 +241,7 @@ Notes:
|
||||||
* HCL
|
* HCL
|
||||||
* `terraform-fmt`
|
* `terraform-fmt`
|
||||||
* HTML
|
* HTML
|
||||||
|
* `VSCode HTML language server`
|
||||||
* `alex`
|
* `alex`
|
||||||
* `angular`
|
* `angular`
|
||||||
* `cspell`
|
* `cspell`
|
||||||
|
|
|
@ -643,7 +643,7 @@ displayed.
|
||||||
ALE supports jumping to the files and locations where symbols are implemented
|
ALE supports jumping to the files and locations where symbols are implemented
|
||||||
through any enabled LSP linters. The locations ALE will jump to depend on the
|
through any enabled LSP linters. The locations ALE will jump to depend on the
|
||||||
information returned by LSP servers. The |ALEGoToImplementation| command will
|
information returned by LSP servers. The |ALEGoToImplementation| command will
|
||||||
jump to the implementation of symbols under the cursor. See the documentation
|
jump to the implementation of symbols under the cursor. See the documentation
|
||||||
for the command for configuring how the location will be displayed.
|
for the command for configuring how the location will be displayed.
|
||||||
|
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
|
@ -2806,6 +2806,7 @@ documented in additional help files.
|
||||||
fecs..................................|ale-css-fecs|
|
fecs..................................|ale-css-fecs|
|
||||||
prettier..............................|ale-css-prettier|
|
prettier..............................|ale-css-prettier|
|
||||||
stylelint.............................|ale-css-stylelint|
|
stylelint.............................|ale-css-stylelint|
|
||||||
|
vscodecss.............................|ale-css-vscode|
|
||||||
cuda....................................|ale-cuda-options|
|
cuda....................................|ale-cuda-options|
|
||||||
nvcc..................................|ale-cuda-nvcc|
|
nvcc..................................|ale-cuda-nvcc|
|
||||||
clangd................................|ale-cuda-clangd|
|
clangd................................|ale-cuda-clangd|
|
||||||
|
@ -2920,6 +2921,7 @@ documented in additional help files.
|
||||||
prettier..............................|ale-html-prettier|
|
prettier..............................|ale-html-prettier|
|
||||||
stylelint.............................|ale-html-stylelint|
|
stylelint.............................|ale-html-stylelint|
|
||||||
tidy..................................|ale-html-tidy|
|
tidy..................................|ale-html-tidy|
|
||||||
|
vscodehtml............................|ale-html-vscode|
|
||||||
write-good............................|ale-html-write-good|
|
write-good............................|ale-html-write-good|
|
||||||
idris...................................|ale-idris-options|
|
idris...................................|ale-idris-options|
|
||||||
idris.................................|ale-idris-idris|
|
idris.................................|ale-idris-idris|
|
||||||
|
@ -3425,7 +3427,7 @@ ALEGoToTypeDefinition *ALEGoToTypeDefinition*
|
||||||
ALEGoToImplementation *ALEGoToImplementation*
|
ALEGoToImplementation *ALEGoToImplementation*
|
||||||
|
|
||||||
This works similar to |ALEGoToDefinition| but instead jumps to the
|
This works similar to |ALEGoToDefinition| but instead jumps to the
|
||||||
implementation of symbol under the cursor. ALE will jump to a definition if
|
implementation of symbol under the cursor. ALE will jump to a definition if
|
||||||
an LSP server provides a location to jump to. Otherwise, ALE will do nothing.
|
an LSP server provides a location to jump to. Otherwise, ALE will do nothing.
|
||||||
|
|
||||||
The locations opened in different ways using the following variations.
|
The locations opened in different ways using the following variations.
|
||||||
|
|
|
@ -123,6 +123,7 @@ formatting.
|
||||||
* [ameba](https://github.com/veelenga/ameba) :floppy_disk:
|
* [ameba](https://github.com/veelenga/ameba) :floppy_disk:
|
||||||
* [crystal](https://crystal-lang.org/) :floppy_disk:
|
* [crystal](https://crystal-lang.org/) :floppy_disk:
|
||||||
* CSS
|
* CSS
|
||||||
|
* [VSCode CSS language server](https://github.com/hrsh7th/vscode-langservers-extracted)
|
||||||
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell)
|
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell)
|
||||||
* [csslint](http://csslint.net/)
|
* [csslint](http://csslint.net/)
|
||||||
* [fecs](http://fecs.baidu.com/)
|
* [fecs](http://fecs.baidu.com/)
|
||||||
|
@ -249,6 +250,7 @@ formatting.
|
||||||
* HCL
|
* HCL
|
||||||
* [terraform-fmt](https://github.com/hashicorp/terraform)
|
* [terraform-fmt](https://github.com/hashicorp/terraform)
|
||||||
* HTML
|
* HTML
|
||||||
|
* [VSCode HTML language server](https://github.com/hrsh7th/vscode-langservers-extracted)
|
||||||
* [alex](https://github.com/get-alex/alex)
|
* [alex](https://github.com/get-alex/alex)
|
||||||
* [angular](https://www.npmjs.com/package/@angular/language-server)
|
* [angular](https://www.npmjs.com/package/@angular/language-server)
|
||||||
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell)
|
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell)
|
||||||
|
@ -292,7 +294,7 @@ formatting.
|
||||||
* [tsserver](https://github.com/Microsoft/TypeScript/wiki/Standalone-Server-%28tsserver%29)
|
* [tsserver](https://github.com/Microsoft/TypeScript/wiki/Standalone-Server-%28tsserver%29)
|
||||||
* [xo](https://github.com/sindresorhus/xo)
|
* [xo](https://github.com/sindresorhus/xo)
|
||||||
* JSON
|
* JSON
|
||||||
* [VSCode JSON language server](https://www.npmjs.com/package/vscode-json-languageserver)
|
* [VSCode JSON language server](https://github.com/hrsh7th/vscode-langservers-extracted)
|
||||||
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell) :warning:
|
* [cspell](https://github.com/streetsidesoftware/cspell/tree/main/packages/cspell) :warning:
|
||||||
* [dprint](https://dprint.dev)
|
* [dprint](https://dprint.dev)
|
||||||
* [eslint](http://eslint.org/) :warning:
|
* [eslint](http://eslint.org/) :warning:
|
||||||
|
|
Loading…
Reference in New Issue