New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs(lsp): fix the way of removing items from skipped_servers #2887
Merged
kylo252
merged 2 commits into
LunarVim:rolling
from
mende1:fix/lsp-remove-skipped-servers
Sep 1, 2022
Merged
docs(lsp): fix the way of removing items from skipped_servers #2887
kylo252
merged 2 commits into
LunarVim:rolling
from
mende1:fix/lsp-remove-skipped-servers
Sep 1, 2022
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
related #2503 |
@kylo252 This should be fine? fwiw, that's what I do and been recommending over discord. This resolves the issue without doing anything special, since it's just a lua table. @mende1 Can you squash it and fix the commit linter warning?
|
- on: config.example.lua - why? because tbl_map just return a list of booleans and tbl_filter return a list of items filtered by certain function
kylo252
force-pushed
the
fix/lsp-remove-skipped-servers
branch
from
September 1, 2022 11:39
32bc5ca
to
e47d5e7
Compare
kylo252
approved these changes
Sep 1, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
kylo252
changed the title
fix(lsp): fix the way of removing items from skipped_servers
docs(lsp): fix the way of removing items from skipped_servers
Sep 1, 2022
tomazursic
pushed a commit
to tomazursic/LunarVim
that referenced
this pull request
Sep 14, 2022
* upstream/rolling: fix(plugins): handle deprecated options (LunarVim#3014) fix(core/autocmds): do not check for existence on clear_augroup (LunarVim#2963) fix(cmp): fix cmp select on CR (LunarVim#2980) fix(plugins): bring back original folke repos (LunarVim#2992) chore: bump plugins version (LunarVim#2972) fix(cmp): do not mutate the original confirm_opts on CR (LunarVim#2979) docs(lsp): fix the way of removing items from skipped_servers (LunarVim#2887) chore: remove unnecessary code (LunarVim#2923) chore: bump plugins version (LunarVim#2925) fix(ts_context_commentstring): block comment match new api (LunarVim#2948) fix(lsp): pass name arg to should_auto_install (LunarVim#2958) refactor(cmp)!: adapt new recommendations (LunarVim#2913) fix: update key bindings for comment.nvim to use new api (LunarVim#2926)
tomazursic
pushed a commit
to tomazursic/LunarVim
that referenced
this pull request
Sep 14, 2022
* upstream/master: (30 commits) fix(plugins): handle deprecated options (LunarVim#3014) fix(core/autocmds): do not check for existence on clear_augroup (LunarVim#2963) fix(cmp): fix cmp select on CR (LunarVim#2980) fix(plugins): bring back original folke repos (LunarVim#2992) chore: bump plugins version (LunarVim#2972) fix(cmp): do not mutate the original confirm_opts on CR (LunarVim#2979) docs(lsp): fix the way of removing items from skipped_servers (LunarVim#2887) chore: remove unnecessary code (LunarVim#2923) chore: update changelog chore: bump plugins version (LunarVim#2925) fix(ts_context_commentstring): block comment match new api (LunarVim#2948) fix(lsp): pass name arg to should_auto_install (LunarVim#2958) refactor(cmp)!: adapt new recommendations (LunarVim#2913) fix: update key bindings for comment.nvim to use new api (LunarVim#2926) chore: bump plugins version (LunarVim#2895) feat(installer): handle INSTALL_PREFIX not on PATH (LunarVim#2912) docs: fix automatic_servers_installation example (LunarVim#2918) docs: fix some typos and enhance readability (LunarVim#2917) fix(statusline): display null-ls linters properly (LunarVim#2921) docs(windows): update example config (LunarVim#2919) ...
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
The currently way to remove items from skipped_servers list doesn't make any effect on the original list
lvim.lsp.automatic_configuration.skipped_servers
:The function
vim.tbl_map
only returns a new list with the certain function applied, and doesn't modify the original one. Also, by the examplereturn server ~= "emmet_ls"
, it doesn't return the list with filtered values, and yes a list with booleans resulted by the function.The solution for this is just assigning the returned list from the
vim.tbl_map
function inside the original listlvim.lsp.automatic_configuration.skipped_servers
and also changing the function tovim.tbl_filter
, because this way makes sense with the function used in the examplereturn server ~= "emmet_ls"
to recieve a list with filtered values.Fixes #2501