Commit Graph

82 Commits

Author SHA1 Message Date
dundargoc
f7ccf006df Remove mention of neovim as the checkhealth syntax is deprecated there (#1525)
Co-authored-by: Prabir Shrestha <mail@prabir.me>
2024-02-25 03:09:29 -08:00
David Briscoe
0c8fda7921 Print workspace_config with :verbose LspStatus (#1279)
* Make verbose LspStatus show workspace config

Need the trailing echo to ensure the next lsp server is on a new line.

* Use pretty printing if available

* checkhealth: Print server status and config

Add initial checkhealth support.
See https://github.com/rhysd/vim-healthcheck

Lists server status, advice for failure, and lists workspace config to
help debug issues or understand server state. Doesn't do much error
detecting.

* checkhealth: Print each server config as a section

checkhealth doesn't allow a lot of formatting (no indentation), so it's
hard to make the config output readable. Output each server as a
separate section instead of one giant config block to make the start of
each server easier to see.
2022-10-29 10:43:57 -07:00
Lie Ryan
2bb97d2938 Replace references to pylsp with pyls (#1378)
The palantir pyls repository is no longer maintained, the documentation
should not lead user down the path of configuring this dead end project.
pylps is the actively maintained sucessor project forked from pyls.
2022-10-16 20:30:19 -07:00
Prabir Shrestha
40b155512b use nnoremap for scroll since it is usually in normal mode when opening popup (#1161) (#1258) 2022-01-04 00:54:16 -08:00
Geoffrey Huntley
7e8812bbb7 docs: add opencollective integration to the readme (#1196) 2021-06-10 18:28:20 -07:00
Daisuke Suzuki
541ed984b1 Add LspAddTreeCallHierarchyIncoming (#1139) 2021-05-31 13:41:41 -07:00
rhysd
6f8f49c96e include maintainers information in document
so that users can easily contact to maintainers without making issues on
repository.
2021-04-03 01:26:07 +09:00
Jaen
350b3219cf Clarify that vim-plug should be installed first (#1114) 2021-03-20 10:59:38 -07:00
Linda_pp
8a39ef5904 Add integration tests with gopls instead of rust-analyzer (#1108)
* Revert "remove flaky integration tests (#1098)"

This reverts commit 78c107085a.

* use gopls for integration tests instead of rust-analyzer

* specific Go and gopls versions via envvar on CI

* remove unused test helper for Rust test project

based on https://github.com/prabirshrestha/vim-lsp/pull/1108#discussion_r595689580

* include multibyte text in integration test case

based on https://github.com/prabirshrestha/vim-lsp/pull/1108#discussion_r595690354

* cache gopls binary on running CI workflows

* update doc to run integ tests
2021-03-20 10:54:17 -07:00
hrsh7th
6a2b97cd59 Add scroll keymapping (#1058)
* Add lsp#scroll function

* Update README.md

* Add example setting to docs
2021-02-22 20:51:48 +09:00
Daisuke Suzuki
17180038a8 add support for call hierarchy (#1046)
* add support for call hierarchy

* no need to use a timer

https://github.com/prabirshrestha/vim-lsp/pull/1046#discussion_r559003701

* add commands to README.md
2021-01-17 18:44:25 -08:00
Prabir Shrestha
7442e27a76 add lsp-workspace-symbol-search example in README.md 2021-01-10 20:17:23 +00:00
Prabir Shrestha
e699b0fcb6 add LspDocumentSymbolSearch using quickpick (#1029) 2021-01-09 12:14:26 -08:00
Linda_pp
513fef901e Fix typos in documents (#1012) 2021-01-03 01:34:32 -08:00
Prabir Shrestha
efd07d859e Revamp diagnostics highlights (#995) 2020-12-31 23:13:19 -08:00
Prabir Shrestha
5743ae2110 Diagnostics signs revamp (#994) 2020-12-31 01:23:26 -08:00
Prabir Shrestha
1489cf8295 Revamp diagnostics virtual text (#990) 2020-12-30 14:49:44 -08:00
Martin Kourim
2a573f1321 Update the Highlight references section in README (#988)
Closes https://github.com/prabirshrestha/vim-lsp/issues/987
2020-12-30 17:23:14 +00:00
Prabir Shrestha
4ff1d41412 [WIP] do not merge: integration tests with language servers (#959)
* download rust-analyzer

* added empty testproject-rust

* add integration tests for LspDocumentFormatSync

* wipeout all buffer

* set shiftwidth and tabstop

* set gobal shiftwidth and tabstop

* remove tabstop

* sleep 100m

* remove l:got

* get latest line

* sleep 4000m

* use setl shiftwidth=4

* use %bwipeout!

* wait for rust-analyzer to start

* fix lint issues

* indent left

* remove log

* disable log

* set timeout to 10sec

* add 100m sleep

* download rust-analyzer for linux neovim

* add message to diagnostics test

* severity is optional in diagnostics

* download rust-analyzer for mac_neovim

* update README.md with test section
2020-12-23 20:10:22 -08:00
Prabir Shrestha
b316729ef5 use callbag to implement document format with timeout (#956)
* use callbag to implement document format with timeout

* document lsp#stream() with example

* send message to stream when using lsp#_new_command

* use -- for args parsing and add g:lsp_document_format_sync_timeout

* throw string exception

* use new func for <plug>(lsp-document-format)

* document g:lsp_format_sync_timeout

* rename to document_formatting

* add document_range_formatting.vim

* remove formatting from ui/vim.vim

* document :LspDocumentRangeFormatSync

* add LspDocumentFormatSync example in README.md
2020-12-22 22:08:32 -08:00
Prabir Shrestha
32fae1f0e9 use allowlist and blocklist instead (#847)
* use allowlist and blocklist instead
* add lsp#get_allowed_servers()
2020-06-26 16:13:09 -07:00
Prabir Shrestha
1db6be9147 added keybinding examples 2020-06-24 23:52:10 -07:00
Prabir Shrestha
1fd74e47eb remove refrences to async.vim 2020-06-20 23:15:29 +00:00
ujihisa
33dcddfbe6 Trivial typofix (#836) 2020-06-11 08:25:53 +09:00
Daisuke Suzuki
18f2e922f7 Add support for code lens (#831) 2020-06-09 22:45:20 -07:00
Prabir Shrestha
b5d2097a5f Update README.md 2020-05-26 21:36:02 -07:00
John Schug
2ca2fe3854 Add support for the tagfunc option (#815)
* Add support for tagfunc option

* Consolidate various synchronous wait implementations

* Refactor to use lsp#utils#position#lsp_to_vim

Also marks get_symbol_text_from_kind as internal and fixes compatibility
with older vims.
2020-05-25 14:41:21 -07:00
Prabir Shrestha
3d0153bcf9 improve diff by using lua if available (#821)
* use lua if available for diff

* add docs

* sync with latest vim-lsc changes

* lazily init lua

* update vim to 8.2.0817

* update vim to 8.2.0817 for windows

* use vim 8.2.0814

* check for path 8.2.0775 before enabling lua

* use vim 8.2.0813 since it exists for both linux and windows

* update lua patch check

* optimize vimscript diff by using range

* fix lint issues
2020-05-24 13:03:32 -07:00
Cody Buell
a943fe558d Add ability to set unique hi for virtual text (#811)
Have virtual text default to vim-lsp defaults for each severity sign,
follow any set or link for a user defined Lsp*Text highlight group, but
allow for unique hi for Lsp*Virtual.

Updated documentation to reflect changes.  Fixed typo in README.md.
2020-05-08 21:37:30 -07:00
Phu Nguyen Anh
5f8f3fbeb7 Small typo (#794) 2020-04-19 09:56:44 -07:00
Prabir Shrestha
fabb572f7e document vim-vsnip for snippets (#710) 2020-02-09 09:20:39 -08:00
Prabir Shrestha
67caa411c8 add initial support for type hierarchy (#641) 2019-12-31 17:12:55 -08:00
Thomas Faingnaert
2f725fb4c3 Implement semantic highlighting (#464) 2019-12-26 10:08:30 -08:00
Prabir Shrestha
6dd95bbcab document lsp_buffer_enabled in README.md (#627) 2019-12-25 23:43:56 -08:00
Prabir Shrestha
e4422f660b add official link sto vim-lsp-settings instructions (#623) 2019-12-25 15:15:28 -08:00
Shumpei Shiina
feefc53ea6 Jump to next/previous diagnostics other than error diagnostics (#587)
- add LspNextWarning, LspPreviousWarning commands to jump to warnings
- add LspNextDiagnostic, LspPreviousDiagnostic commands to jump to
  all kinds of diagnostics
2019-12-14 09:07:05 -08:00
Prabir Shrestha
a0b859d9ae Add gitter chat link (#526) 2019-09-29 00:24:26 -07:00
Prabir Shrestha
5fafaa3d72 Disable highlight ref by default (#492)
* disable highlight references by default since it is executes request on every cursor change

* update higlight text

* fix doc
2019-09-08 11:10:36 -07:00
Thomas Faingnaert
698eccaff3 Implement folding (#445)
* Implement folding

* Allow disabling folding globally
2019-09-08 19:17:29 +02:00
Thomas Faingnaert
813ea77b91 Add LspPeekDefinition (#412)
* Add LspPeekDefinition

* Add documentation

* Add lsp-peek-definition mapping to documentation

* Add link to Vim preview-window help

* Rewrite LspPeekDefinition using preview window

* Implement peek for Vim popup window

* Make LspPeekDefinition work in Neovim

* Support align in Neovim

* Fix linter errors

* Extract duplicate code to s:align_preview function

* Merge setlocal settings in one line

* Remove suppress_close

* Clean up cursor movement for preview window

* Move Neovim cursor code to separate function

* Allow customising peek alignment

* Move Vim alignment code to separate function

* Implement Vim alignment of popup window

* Cleanup

* Remove extraneous lines

* Move set_cursor logic

* Move scrolloff setting

* Make function calls a bit more consistent

* Vim popup window fixes

* Remove extraneous call

* Fix Vim alignment

* Remove hardcoded width

* Add abort to closure function

* Fix artifacts

* Fix wrong height if popup above cursor

* Add remaining Peek commands

Add LspPeekImplementation, LspPeekTypeDefinition and LspPeekDeclaration.

* Fix wrong positioning of Vim popup
2019-07-21 09:40:19 -07:00
Thomas Faingnaert
20f5b7541a UltiSnips integration (#306)
* Implement basic UltiSnips integration

* Fix already inserted text not being removed

* Fix incorrect whitespace when nesting snippets

* Fix tabstops not working in nested snippets

* Make functions abort on error

* Check if Vim has the user_data patch

* Add basic documentation

* Add explanation UltiSnips integration to README

* Use single quoted string in plugin/lsp.vim

* Allow plugins to override get_completion_item

* Remove UltiSnips specific code to set user_data

* Remove CompleteDone autocmd from omni.vim

* Revert "Add explanation UltiSnips integration to README"

This reverts commit ee12343cbf.

* Revert "Add basic documentation"

This reverts commit 979275bb4f.

* Allow changing supported capabilities

* Remove g:lsp_ultisnips_integration

* Mention snippets in READE and documentation

* Add documentation for new configuration options

* Pass server_info to get_capabilities

* Change configuration variables to be a List

This way, we don't need to start them with a capital letter.

* Add lsp_complete_done autocmd

* Add documentation of lsp_complete_done
2019-06-15 12:06:16 -07:00
tsufeki
c1be742774 Add diagnostics highlighting via +textprop. (#375)
* Add diagnostics highlighting via +textprop.

* Use textprop 'combine' option, added in 8.1.1276

* Add textprop docs.

* Enable textprop highlights by default.
2019-05-17 03:02:38 -07:00
Martino Pilia
fe5057641c Highlight references to the symbol under cursor (#363)
* Highlight references to the symbol under cursor

Use the `textDocument/documentHighlight` method to retrieve references
to the symbol under the cursor, and highlight them with matchaddpos().
Add the commands `LscPreviusReference` and `LscNextReference` to
navigate between references within the buffer.

Adaption from the implementation of "Highlight references" in vim-lsc:
https://github.com/natebosch/vim-lsc/blob/5b587b0c/autoload/lsc/cursor.vim

* Fixups

+ Lapsus: `while` statement where it should be `if`.
+ Fix alignment in docs.

* Update LICENSE-THIRD-PARTY
2019-04-21 13:39:26 -07:00
Łukasz Niemier
cedacac6fc Support NeoVim virtual text
Currently it uses similar interface to one provided by the signs
feature.

Close #214
2019-03-07 20:05:28 +01:00
Prabir Shrestha
629a50140f use supports 2019-01-14 11:53:46 -08:00
Yasuhiro Matsumoto
94f3272c56 Note that vim-lsp support incremental changes 2019-01-14 11:53:46 -08:00
Prabir Shrestha
896c747c62 add support for :LspDeclaration (#243)
* add support for :LspDeclaration
* update docs and add plug mappings
2019-01-13 15:21:20 -08:00
Yasuhiro Matsumoto
51f8e393d1 Fix link to ALE 2019-01-08 09:05:24 +09:00
Matteo Landi
ac22efb91e Add flag to disable diagnostics (#197)
* Add switch, g:lsp_diagnostics_enabled, to disable support for diagnostics

* Reduce PR changeset
2019-01-01 20:43:46 -08:00
Ryan Badour
832be4e92e Update README.md (#217)
Added :LspStatus to list of commands and sorted the list alphabetically.
2018-12-18 13:16:22 -08:00