mirror of
https://github.com/LunarVim/LunarVim.git
synced 2025-08-31 07:09:23 +02:00
Merge branch 'master' of github.com:ChristianChiarulli/nvcode
This commit is contained in:
commit
cd764de1bf
10 changed files with 25 additions and 17 deletions
2
init.lua
2
init.lua
|
@ -48,8 +48,10 @@ require('lsp')
|
||||||
require('lsp.clangd')
|
require('lsp.clangd')
|
||||||
require('lsp.lua-ls')
|
require('lsp.lua-ls')
|
||||||
require('lsp.bash-ls')
|
require('lsp.bash-ls')
|
||||||
|
require('lsp.go-ls')
|
||||||
require('lsp.js-ts-ls')
|
require('lsp.js-ts-ls')
|
||||||
require('lsp.python-ls')
|
require('lsp.python-ls')
|
||||||
|
require('lsp.rust-ls')
|
||||||
require('lsp.json-ls')
|
require('lsp.json-ls')
|
||||||
require('lsp.yaml-ls')
|
require('lsp.yaml-ls')
|
||||||
require('lsp.vim-ls')
|
require('lsp.vim-ls')
|
||||||
|
|
|
@ -13,6 +13,7 @@ local flake8 = {
|
||||||
local isort = {formatCommand = "isort --quiet -", formatStdin = true}
|
local isort = {formatCommand = "isort --quiet -", formatStdin = true}
|
||||||
|
|
||||||
local yapf = {formatCommand = "yapf --quiet", formatStdin = true}
|
local yapf = {formatCommand = "yapf --quiet", formatStdin = true}
|
||||||
|
local black = {formatCommand = "black --quiet --stdin-filename ", formatStdin = true}
|
||||||
|
|
||||||
if O.python.linter == 'flake8' then
|
if O.python.linter == 'flake8' then
|
||||||
table.insert(python_arguments, flake8)
|
table.insert(python_arguments, flake8)
|
||||||
|
@ -20,6 +21,8 @@ end
|
||||||
|
|
||||||
if O.python.formatter == 'yapf' then
|
if O.python.formatter == 'yapf' then
|
||||||
table.insert(python_arguments, yapf)
|
table.insert(python_arguments, yapf)
|
||||||
|
elseif O.python.formatter == 'black' then
|
||||||
|
table.insert(python_arguments, black)
|
||||||
end
|
end
|
||||||
|
|
||||||
if O.python.isort then
|
if O.python.isort then
|
||||||
|
|
4
lua/lsp/go-ls.lua
Normal file
4
lua/lsp/go-ls.lua
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
require'lspconfig'.gopls.setup{
|
||||||
|
cmd = {DATA_PATH .. "/lspinstall/go/gopls"},
|
||||||
|
on_attach = require'lsp'.common_on_attach
|
||||||
|
}
|
5
lua/lsp/rust-ls.lua
Normal file
5
lua/lsp/rust-ls.lua
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
require'lspconfig'.rust_analyzer.setup{
|
||||||
|
cmd = {DATA_PATH .. "/lspinstall/rust/rust-analyzer"},
|
||||||
|
on_attach = require'lsp'.common_on_attach
|
||||||
|
}
|
||||||
|
|
|
@ -39,7 +39,6 @@
|
||||||
--
|
--
|
||||||
--
|
--
|
||||||
-- remap('i' , '<CR>','v:lua.MUtils.completion_confirm()', {expr = true , noremap = true})
|
-- remap('i' , '<CR>','v:lua.MUtils.completion_confirm()', {expr = true , noremap = true})
|
||||||
|
|
||||||
-- TODO switch to lua plugin when possible
|
-- TODO switch to lua plugin when possible
|
||||||
vim.cmd([[
|
vim.cmd([[
|
||||||
let g:lexima_no_default_rules = v:true
|
let g:lexima_no_default_rules = v:true
|
||||||
|
|
|
@ -4,7 +4,7 @@ O = {
|
||||||
colorscheme = 'nvcode',
|
colorscheme = 'nvcode',
|
||||||
python = {
|
python = {
|
||||||
linter = '',
|
linter = '',
|
||||||
-- @usage can be 'yapf'
|
-- @usage can be 'yapf', 'black'
|
||||||
formatter = '',
|
formatter = '',
|
||||||
autoformat = false,
|
autoformat = false,
|
||||||
isort = false,
|
isort = false,
|
||||||
|
|
|
@ -62,7 +62,6 @@ require('telescope').setup {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
require'telescope'.setup {
|
|
||||||
extensions = {
|
extensions = {
|
||||||
media_files = {
|
media_files = {
|
||||||
-- filetypes whitelist
|
-- filetypes whitelist
|
||||||
|
@ -72,4 +71,3 @@ require('telescope').setup {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
|
@ -5,7 +5,7 @@ require'nvim-treesitter.configs'.setup {
|
||||||
highlight = {
|
highlight = {
|
||||||
enable = true -- false will disable the whole extension
|
enable = true -- false will disable the whole extension
|
||||||
},
|
},
|
||||||
indent = {enable = true},
|
indent = {enable = true, disable = {"python"}},
|
||||||
playground = {
|
playground = {
|
||||||
enable = true,
|
enable = true,
|
||||||
disable = {},
|
disable = {},
|
||||||
|
|
3
test.py
3
test.py
|
@ -1,3 +0,0 @@
|
||||||
|
|
||||||
def thing(parameter_list):
|
|
||||||
pass
|
|
|
@ -3,7 +3,7 @@
|
||||||
" Timeout
|
" Timeout
|
||||||
let g:which_key_timeout = 100
|
let g:which_key_timeout = 100
|
||||||
|
|
||||||
let g:which_key_display_names = {'<CR>': '↵', '<TAB>': '⇆'}
|
let g:which_key_display_names = {'<CR>': '↵', '<TAB>': '⇆', " ": 'SPC'}
|
||||||
|
|
||||||
" Map leader to which_key
|
" Map leader to which_key
|
||||||
nnoremap <silent> <leader> :silent <c-u> :silent WhichKey '<Space>'<CR>
|
nnoremap <silent> <leader> :silent <c-u> :silent WhichKey '<Space>'<CR>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue