162 lines
4.6 KiB
Lua
162 lines
4.6 KiB
Lua
local fn = vim.fn
|
|
|
|
local install_path = fn.stdpath('data')..'/site/pack/packer/start/packer.nvim'
|
|
|
|
if fn.empty(fn.glob(install_path)) > 0 then
|
|
packer_bootstrap = fn.system({
|
|
'git', 'clone', '--depth', '1', 'https://github.com/wbthomason/packer.nvim', install_path
|
|
})
|
|
end
|
|
|
|
return require('packer').startup(function()
|
|
-----------------------------------------------------------------------------
|
|
use { 'wbthomason/packer.nvim' }
|
|
|
|
-----------------------------------------------------------------------------
|
|
use { 'wakatime/vim-wakatime' }
|
|
|
|
-----------------------------------------------------------------------------
|
|
use { 'habamax/vim-godot' }
|
|
|
|
-----------------------------------------------------------------------------
|
|
use { 'Bakudankun/PICO-8.vim' }
|
|
|
|
-----------------------------------------------------------------------------
|
|
use {
|
|
'chriskempson/base16-vim',
|
|
config = function()
|
|
vim.cmd('source ~/.vimrc_background')
|
|
vim.g.base16colorspace = 256
|
|
end,
|
|
}
|
|
|
|
-----------------------------------------------------------------------------
|
|
use {
|
|
'nvim-telescope/telescope.nvim',
|
|
requires = {
|
|
{ 'nvim-lua/plenary.nvim' },
|
|
{ 'kyazdani42/nvim-web-devicons' },
|
|
},
|
|
config = function()
|
|
vim.api.nvim_set_keymap('n', '-',
|
|
':Telescope find_files find_command=rg,--ignore,--ignore-case,--hidden,--files<CR>',
|
|
{ noremap = true })
|
|
end,
|
|
}
|
|
|
|
-----------------------------------------------------------------------------
|
|
use { 'nvim-treesitter/nvim-treesitter', run = ':TSUpdate' }
|
|
|
|
-----------------------------------------------------------------------------
|
|
use {
|
|
'hrsh7th/nvim-cmp',
|
|
requires = {
|
|
{ 'hrsh7th/cmp-vsnip', after = 'nvim-cmp' },
|
|
{ 'hrsh7th/cmp-nvim-lsp', after = 'nvim-cmp' },
|
|
{ 'hrsh7th/cmp-buffer', after = 'nvim-cmp' },
|
|
{ 'hrsh7th/vim-vsnip', after = 'nvim-cmp' },
|
|
},
|
|
config = function()
|
|
local cmp = require('cmp')
|
|
cmp.setup({
|
|
snippet = {
|
|
expand = function(args)
|
|
vim.fn["vsnip#anonymous"](args.body)
|
|
end,
|
|
},
|
|
mapping = {
|
|
['<C-d>'] = cmp.mapping.scroll_docs(-4),
|
|
['<C-f>'] = cmp.mapping.scroll_docs(4),
|
|
['<C-Space>'] = cmp.mapping.complete(),
|
|
['<C-e>'] = cmp.mapping.close(),
|
|
['<CR>'] = cmp.mapping.confirm({ select = true }),
|
|
},
|
|
sources = {
|
|
{ name = 'nvim_lsp' },
|
|
{ name = 'vsnip' },
|
|
{ name = 'buffer' },
|
|
}
|
|
})
|
|
end,
|
|
}
|
|
|
|
-----------------------------------------------------------------------------
|
|
use {
|
|
'neovim/nvim-lspconfig',
|
|
after = 'nvim-cmp',
|
|
config = function()
|
|
lspconfig = require('lspconfig')
|
|
|
|
lspconfig.pyright.setup({
|
|
settings = {
|
|
python = {
|
|
venvPath = "~/.conda/envs",
|
|
analysis = {
|
|
useLibraryCodeForTypes = true,
|
|
}
|
|
}
|
|
}
|
|
})
|
|
|
|
lspconfig.rust_analyzer.setup({})
|
|
|
|
local cmp = require('cmp_nvim_lsp')
|
|
local gd_capabilities = cmp.update_capabilities(
|
|
vim.lsp.protocol.make_client_capabilities()
|
|
)
|
|
lspconfig.gdscript.setup({
|
|
capabilities = gd_capabilities,
|
|
cmd = { 'nc', '127.0.0.1', '6008' },
|
|
})
|
|
|
|
end,
|
|
}
|
|
|
|
-----------------------------------------------------------------------------
|
|
use { 'mhinz/vim-signify' }
|
|
|
|
-----------------------------------------------------------------------------
|
|
use {
|
|
'simrat39/rust-tools.nvim',
|
|
after = 'nvim-lspconfig',
|
|
requires = {
|
|
{ 'neovim/nvim-lspconfig' },
|
|
{ 'nvim-lua/popup.nvim' },
|
|
{ 'nvim-lua/plenary.nvim' },
|
|
},
|
|
config = function()
|
|
require('rust-tools').setup({})
|
|
end,
|
|
}
|
|
|
|
-----------------------------------------------------------------------------
|
|
use {
|
|
'GustavoKatel/sidebar.nvim',
|
|
requires = { { 'GustavoKatel/todo-comments.nvim' } },
|
|
config = function()
|
|
require('sidebar-nvim').setup({
|
|
side = 'right',
|
|
sections = { 'datetime', 'git', 'diagnostics', 'todos' }
|
|
})
|
|
end,
|
|
}
|
|
|
|
-----------------------------------------------------------------------------
|
|
use {
|
|
'famiu/feline.nvim',
|
|
config = function()
|
|
require('feline').setup({ preset = 'noicon' })
|
|
end,
|
|
}
|
|
|
|
-----------------------------------------------------------------------------
|
|
use { 'SuneelFreimuth/vim-gemtext' }
|
|
|
|
-----------------------------------------------------------------------------
|
|
use { 'junegunn/goyo.vim' }
|
|
|
|
-----------------------------------------------------------------------------
|
|
if packer_bootstrap then
|
|
require('packer').sync()
|
|
end
|
|
end)
|