dotfiles/nvim/lua/plugins.lua

143 lines
3.4 KiB
Lua
Raw Normal View History

2022-01-18 01:25:46 -05:00
local bootstrap = require('bootstrap')
local function import(name)
return ([[require '%s']]):format(name)
end
return require('packer').startup({function(use)
use 'wbthomason/packer.nvim'
use {
'vim-airline/vim-airline',
requires = {
'ryanoasis/vim-devicons',
}
}
use {
'tpope/vim-fugitive',
config = function()
local map = vim.api.nvim_set_keymap
map('n', '<Leader>g', '<Cmd>Git<CR>', {noremap = true})
end,
}
use {
'lewis6991/gitsigns.nvim',
requires = {
'nvim-lua/plenary.nvim'
},
config = function()
require('gitsigns').setup {
signs = {
add = {hl = 'GitSignsAdd' , text = '', numhl='GitSignsAddNr' , linehl='GitSignsAddLn'},
change = {hl = 'GitSignsChange', text = '', numhl='GitSignsChangeNr', linehl='GitSignsChangeLn'},
delete = {hl = 'GitSignsDelete', text = '_', numhl='GitSignsDeleteNr', linehl='GitSignsDeleteLn'},
topdelete = {hl = 'GitSignsDelete', text = '', numhl='GitSignsDeleteNr', linehl='GitSignsDeleteLn'},
changedelete = {hl = 'GitSignsChange', text = '~', numhl='GitSignsChangeNr', linehl='GitSignsChangeLn'},
},
}
end
}
use {
'numToStr/Comment.nvim',
config = function()
local map = vim.api.nvim_set_keymap
require('Comment').setup({})
map('n', '<C-_>',
'<Cmd>lua require("Comment.api").toggle_linewise_op(vim.fn.visualmode())<CR>',
{noremap = true, silent = true})
end
}
use {
'nvim-telescope/telescope.nvim',
requires = {
'nvim-lua/plenary.nvim',
{
'nvim-telescope/telescope-fzf-native.nvim',
run = 'make',
},
'nvim-telescope/telescope-symbols.nvim',
},
config = import('tel'),
}
use {
'stevearc/dressing.nvim',
config = function()
require('dressing').setup({
input = {
default_prompt = '',
winhighlight = 'NormalFloat:Normal',
},
})
vim.cmd [[highlight link FloatTitle NonText]]
vim.cmd [[highlight link DressingInputText Normal]]
end,
}
use {
'antoinemadec/FixCursorHold.nvim',
config = function()
vim.g.cursorhold_updatetime = 500
end,
}
use {
'neovim/nvim-lspconfig',
requires = {
'nvim-lua/lsp-status.nvim',
{
'ms-jpq/coq_nvim',
run = ':COQdeps',
requires = {
'ms-jpq/coq.artifacts',
},
},
{
'jose-elias-alvarez/null-ls.nvim',
requires = {
'nvim-lua/plenary.nvim',
},
},
},
config = import('lsp'),
}
use {
'lervag/vimtex',
config = function()
vim.g.vimtex_view_general_viewer = 'zathura'
2022-02-15 16:08:17 -05:00
-- vim.g.vimtex_view_general_options = = '-x nvim -n -c "Vimtex'
-- 'file:@pdf\\#src:@line@tex'
2022-01-18 01:25:46 -05:00
vim.g.vimtex_quickfix_enabled = 0
vim.g.Tex_GotoError = 0
vim.g.Tex_ShowErrorContext = 0
end,
}
use {
'iamcco/markdown-preview.nvim',
run = "cd app && npm install",
setup = function() vim.g.mkdp_filetypes = { "markdown" } end, ft = { "markdown" },
config = function()
local map = vim.api.nvim_set_keymap
map('n', '<C-m>', '<Plug>MarkdownPreviewToggle', {})
map('n', '<Leader>m', '<Plug>MarkdownPreviewToggle', {})
2022-02-15 11:02:08 -05:00
vim.g.mkdp_markdown_css = os.getenv("HOME") .. "/.config/nvim/lua/markdownStyle.css"
vim.g.mkdp_highlight_css = os.getenv("HOME") .. "/.cache/wal/colors.css"
2022-01-18 01:25:46 -05:00
end
}
2022-02-15 16:08:17 -05:00
2022-01-18 01:25:46 -05:00
if bootstrap.is_bootstrap then
require('packer').sync()
end
end,
config = {
compile_path = require('packer.util').join_paths(vim.fn.stdpath('data'), 'site', 'plugin', 'packer_compiled.lua'),
}})