-
Notifications
You must be signed in to change notification settings - Fork 0
/
plugins.lua
109 lines (104 loc) · 5.58 KB
/
plugins.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
--------------------------------------------------------------------------------
-- Plugins --
--------------------------------------------------------------------------------
-- Runtime path
local lazypath = vim.fn.stdpath('data') .. '/lazy/lazy.nvim'
---@diagnostic disable-next-line: undefined-field
if not vim.uv.fs_stat(lazypath) then
vim.fn.system({
'git',
'clone',
'--filter=blob:none',
'https://github.com/folke/lazy.nvim.git',
'--branch=stable', -- latest stable release
lazypath,
})
end
vim.opt.rtp:prepend(lazypath)
local settings = require('plugins.settings')
local key_bindings = require('plugins.key_bindings')
require('lazy').setup {
spec = {
{
'tanvirtin/monokai.nvim',
config = settings.setup_monokai_nvim,
lazy = false,
priority = 1000
},
{ 'nvim-lua/plenary.nvim', lazy = true },
{ 'nvim-tree/nvim-web-devicons', lazy = true },
{ 'neovim/nvim-lspconfig', lazy = true },
{ 'nvim-treesitter/nvim-treesitter', config = settings.setup_nvim_treesitter, event = 'VeryLazy' },
{ 'nvim-lualine/lualine.nvim', config = settings.setup_lualine_nvim, event = 'BufWinEnter' },
{ 'willothy/nvim-cokeline', config = settings.setup_nvim_cokeline, event = { 'BufAdd', 'TabNew' } },
{ 'kazhala/close-buffers.nvim', config = settings.setup_close_buffers_nvim, keys = { '<leader>b', '<leader>B' } },
{ 'ten3roberts/qf.nvim', config = settings.setup_qf_nvim, event = 'VeryLazy' },
{ 'NMAC427/guess-indent.nvim', config = settings.setup_guess_indent_nvim, event = { 'BufNewFile', 'BufReadPost' } },
{ 'lukas-reineke/indent-blankline.nvim', config = settings.setup_indent_blankline_nvim, event = 'VeryLazy' },
{ 'folke/flash.nvim', config = settings.setup_flash_nvim, event = 'VeryLazy' },
{ 'folke/ts-comments.nvim', opts = {}, event = 'VeryLazy' },
{ 'windwp/nvim-autopairs', config = settings.setup_nvim_autopairs, event = 'InsertEnter' },
{ 'kylechui/nvim-surround', config = settings.setup_nvim_surround, event = 'VeryLazy' },
{ 'ahmedkhalf/project.nvim', config = settings.setup_project_nvim, event = 'VimEnter' },
{
'nvim-telescope/telescope.nvim',
dependencies = {
{ 'nvim-telescope/telescope-fzf-native.nvim', build = 'make' },
'nvim-telescope/telescope-live-grep-args.nvim',
{ 'stevearc/aerial.nvim', config = settings.setup_aerial_nvim, keys = '<leader>a' },
},
config = settings.setup_telescope_nvim,
keys = { '<leader>ff', '<leader>fg', '<leader>fb', '<leader>fh', '<leader>fw', '<leader>fa' },
},
{
'hrsh7th/nvim-cmp',
dependencies = {
{ 'saadparwaiz1/cmp_luasnip', dependencies = { 'L3MON4D3/LuaSnip', build = 'make install_jsregexp' } },
'hrsh7th/cmp-buffer',
'hrsh7th/cmp-path',
'hrsh7th/cmp-cmdline',
'rafamadriz/friendly-snippets',
},
config = settings.setup_nvim_cmp,
event = { 'InsertEnter', 'CmdlineEnter' },
},
{
'williamboman/mason.nvim',
dependencies = {
'williamboman/mason-lspconfig.nvim',
'hrsh7th/cmp-nvim-lsp',
},
config = settings.setup_lsp,
event = { 'BufNewFile', 'BufReadPost' }
},
{ 'mrcjkb/rustaceanvim', version = '*', ft = 'rust' },
{
'mfussenegger/nvim-dap',
dependencies = {
{
'rcarriga/nvim-dap-ui',
dependencies = { { 'nvim-neotest/nvim-nio', lazy = true } },
config = settings.setup_nvim_dap_ui,
},
{ 'theHamsta/nvim-dap-virtual-text', config = settings.setup_nvim_dap_virtual_text }
},
config = settings.setup_dap,
keys = { '<m-k>', '<m-b>', '<m-B>', '<m-p>', '<m-c>' },
event = 'BufNewFile launch.json',
},
{ 'LiadOz/nvim-dap-repl-highlights', config = true, ft = 'dap-repl' },
{ 'norcalli/nvim-colorizer.lua', config = settings.setup_nvim_colorizer_lua, event = 'VeryLazy' },
{ 'nvim-focus/focus.nvim', config = settings.setup_focus_nvim, event = 'BufEnter' },
{ 'sindrets/diffview.nvim', config = settings.setup_diffview_nvim, event = 'VeryLazy' },
-- Vim plugins
{ 'axelf4/vim-strip-trailing-whitespace', event = { 'BufNewFile', 'BufReadPost' } },
{ 'mattn/emmet-vim', ft = { 'html', 'xml' } },
{ 'azabiong/vim-highlighter', keys = 'f' },
{ 'junegunn/vim-easy-align', config = key_bindings.setup_vim_easy_align_keymaps, keys = { { '<enter>', mode = 'x' }, 'ga' } },
{ 'segeljakt/vim-silicon', config = settings.setup_vim_silicon, event = 'CmdlineEnter' },
},
checker = {
enabled = true,
notify = false,
},
}