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
e1fc3d3a
Commit
e1fc3d3a
authored
Jul 19, 2021
by
Tim van Deurzen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update neovim config.
parent
2a418040
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
77 additions
and
30 deletions
+77
-30
neovim/lua/lsp/init.lua
neovim/lua/lsp/init.lua
+56
-25
neovim/lua/plugins/init.lua
neovim/lua/plugins/init.lua
+19
-3
neovim/lua/treesitter/init.lua
neovim/lua/treesitter/init.lua
+2
-2
No files found.
neovim/lua/lsp/init.lua
View file @
e1fc3d3a
...
@@ -19,6 +19,10 @@ lsp_config.rust_analyzer.setup{
...
@@ -19,6 +19,10 @@ lsp_config.rust_analyzer.setup{
capabilities
=
capabilities
,
capabilities
=
capabilities
,
}
}
lsp_config
.
angularls
.
setup
{
capabilities
=
capabilities
,
}
lsp_config
.
yamlls
.
setup
{
lsp_config
.
yamlls
.
setup
{
capabilities
=
capabilities
,
capabilities
=
capabilities
,
}
}
...
@@ -59,8 +63,35 @@ lsp_config.sumneko_lua.setup{
...
@@ -59,8 +63,35 @@ lsp_config.sumneko_lua.setup{
},
},
}
}
local
eslint
=
{
lintCommand
=
"eslint_d -f unix --stdin --stdin-filename ${INPUT}"
,
lintStdin
=
true
,
lintFormats
=
{
"%f:%l:%c: %m"
},
lintIgnoreExitCode
=
true
,
formatCommand
=
"eslint_d --fix-to-stdout --stdin --stdin-filename=${INPUT}"
,
formatStdin
=
true
}
lsp_config
.
efm
.
setup
{
init_options
=
{
documentFormatting
=
true
},
filetypes
=
{
"javascript"
,
"typescript"
},
root_dir
=
function
(
fname
)
return
lsp_config
.
util
.
root_pattern
(
"tsconfig.json"
)(
fname
)
or
lsp_config
.
util
.
root_pattern
(
".eslintrc.js"
,
".git"
)(
fname
);
end
,
settings
=
{
rootMarkers
=
{
".eslintrc.js"
,
".git/"
},
languages
=
{
javascript
=
{
eslint
},
typescript
=
{
eslint
}
}
}
}
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
=
" » "
,
...
@@ -69,7 +100,7 @@ vim.lsp.handlers["textDocument/publishDiagnostics"] = vim.lsp.with(
...
@@ -69,7 +100,7 @@ vim.lsp.handlers["textDocument/publishDiagnostics"] = vim.lsp.with(
},
},
signs
=
true
,
signs
=
true
,
update_in_insert
=
true
,
update_in_insert
=
true
,
}
}
)
)
do
do
...
...
neovim/lua/plugins/init.lua
View file @
e1fc3d3a
...
@@ -204,10 +204,24 @@ return require('packer').startup(function()
...
@@ -204,10 +204,24 @@ return require('packer').startup(function()
config
=
function
()
config
=
function
()
require
(
'lsp_signature'
).
on_attach
({
require
(
'lsp_signature'
).
on_attach
({
bind
=
true
,
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
=
{
handler_opts
=
{
border
=
"single"
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
end
}
}
...
@@ -221,4 +235,6 @@ return require('packer').startup(function()
...
@@ -221,4 +235,6 @@ return require('packer').startup(function()
require
(
'gitsigns'
).
setup
()
require
(
'gitsigns'
).
setup
()
end
end
}
}
use
'tomlion/vim-solidity'
end
)
end
)
neovim/lua/treesitter/init.lua
View file @
e1fc3d3a
...
@@ -18,8 +18,8 @@ ts_configs.setup {
...
@@ -18,8 +18,8 @@ ts_configs.setup {
},
},
refactor
=
{
refactor
=
{
smart_rename
=
{
enable
=
true
,
keymaps
=
{
smart_rename
=
"grr"
}},
smart_rename
=
{
enable
=
true
,
keymaps
=
{
smart_rename
=
"grr"
}},
highlight_definitions
=
{
enable
=
true
}
highlight_definitions
=
{
enable
=
true
}
,
-- highlight_current_scope = { enable = tru
e }
highlight_current_scope
=
{
enable
=
fals
e
}
},
},
textobjects
=
{
textobjects
=
{
select
=
{
select
=
{
...
...
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