Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
dotfiles
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tim van Deurzen
dotfiles
Commits
ab0effe5
Commit
ab0effe5
authored
Aug 13, 2021
by
Tim van Deurzen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update lsp-signature settings and LSP settings.
parent
6944de80
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
33 additions
and
52 deletions
+33
-52
neovim/lua/lsp/init.lua
neovim/lua/lsp/init.lua
+31
-30
neovim/lua/plugins/init.lua
neovim/lua/plugins/init.lua
+2
-22
No files found.
neovim/lua/lsp/init.lua
View file @
ab0effe5
...
@@ -188,34 +188,35 @@ lsp_config.efm.setup {
...
@@ -188,34 +188,35 @@ lsp_config.efm.setup {
}
}
}
}
vim
.
lsp
.
handlers
[
"textDocument/publishDiagnostics"
]
=
vim
.
lsp
.
with
(
-- vim.lsp.handlers["textDocument/publishDiagnostics"] = vim.lsp.with(
vim
.
lsp
.
diagnostic
.
on_publish_diagnostics
,
{
-- vim.lsp.diagnostic.on_publish_diagnostics, {
underline
=
true
,
-- underline = true,
virtual_text
=
{
-- virtual_text = {
prefix
=
" » "
,
-- prefix = " » ",
spacing
=
8
,
-- spacing = 8,
severity_limit
=
"Error"
,
-- severity_limit = "Warning",
},
-- },
signs
=
true
,
-- signs = true,
update_in_insert
=
true
,
-- update_in_insert = true,
}
-- }
)
-- )
do
require
(
'lsp_signature'
).
on_attach
({
local
default_handler
=
vim
.
lsp
.
handlers
[
"textdocument/publishdiagnostics"
]
bind
=
true
,
-- This is mandatory, otherwise border config won't get registered.
vim
.
lsp
.
handlers
[
"textdocument/publishdiagnostics"
]
=
function
(
err
,
method
,
result
,
client_id
,
bufnr
,
config
)
-- If you want to hook lspsaga or other signature handler, pls set to false
default_handler
(
err
,
method
,
result
,
client_id
,
bufnr
,
config
)
doc_lines
=
4
,
-- will show two lines of comment/doc(if there are more than two lines in doc, will be truncated);
local
diagnostics
=
vim
.
lsp
.
diagnostic
.
get_all
()
-- set to 0 if you do not want any API comments be shown
local
qflist
=
{}
-- This setting only take effect in insert mode, it does not affect signature help in normal
for
bufnr_
,
diagnostic
in
pairs
(
diagnostics
)
do
-- mode
for
_
,
d
in
ipairs
(
diagnostic
)
do
d
.
bufnr
=
bufnr_
hint_enable
=
true
,
-- virtual hint enable
d
.
lnum
=
d
.
range
.
start
.
line
+
1
hint_prefix
=
"↑ "
,
-- Panda for parameter
d
.
col
=
d
.
range
.
start
.
character
+
1
hint_scheme
=
"String"
,
d
.
text
=
d
.
message
use_lspsaga
=
false
,
-- set to true if you want to use lspsaga popup
table.insert
(
qflist
,
d
)
handler_opts
=
{
end
border
=
"shadow"
-- double, single, shadow, none
end
},
vim
.
lsp
.
util
.
set_qflist
(
qflist
)
decorator
=
{
"`"
,
"`"
}
-- decoractor can be `decorator = {"***", "***"}` `decorator = {"**", "**"}` `decorator = {"**_", "_**"}`
end
-- `decorator = {"*", "*"} see markdown help for more details
end
-- <u></u> ~ ~ does not supported by nvim
})
neovim/lua/plugins/init.lua
View file @
ab0effe5
...
@@ -202,28 +202,8 @@ return require('packer').startup(function()
...
@@ -202,28 +202,8 @@ return require('packer').startup(function()
use
{
use
{
"ray-x/lsp_signature.nvim"
,
"ray-x/lsp_signature.nvim"
,
config
=
function
()
-- config = function()
require
(
'lsp_signature'
).
on_attach
({
-- end
bind
=
true
,
-- This is mandatory, otherwise border config won't get registered.
-- If you want to hook lspsaga or other signature handler, pls set to false
doc_lines
=
2
,
-- will show two lines of comment/doc(if there are more than two lines in doc, will be truncated);
-- set to 0 if you do not want any API comments be shown
-- This setting only take effect in insert mode, it does not affect signature help in normal
-- mode
hint_enable
=
true
,
-- virtual hint enable
hint_prefix
=
"🐼 "
,
-- Panda for parameter
hint_scheme
=
"String"
,
use_lspsaga
=
false
,
-- set to true if you want to use lspsaga popup
handler_opts
=
{
border
=
"shadow"
-- double, single, shadow, none
},
decorator
=
{
"`"
,
"`"
}
-- decoractor can be `decorator = {"***", "***"}` `decorator = {"**", "**"}` `decorator = {"**_", "_**"}`
-- `decorator = {"*", "*"} see markdown help for more details
-- <u></u> ~ ~ does not supported by nvim
})
end
}
}
use
{
use
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment