]> src.twobees.de Git - dotfiles.git/blob - stow/nvim/.config/nvim/lua/plugin_mgr.lua
...
[dotfiles.git] / stow / nvim / .config / nvim / lua / plugin_mgr.lua
1 local ensure_packer = function()
2     local fn = vim.fn
3     local install_path = fn.stdpath('data')..'/site/pack/packer/start/packer.nvim'
4     if fn.empty(fn.glob(install_path)) > 0 then
5         fn.system({'git', 'clone', '--depth', '1', 'https://github.com/wbthomason/packer.nvim', install_path})
6         vim.cmd [[packadd packer.nvim]]
7         return true
8     end
9     return false
10 end
11
12 local packer_bootstrap = ensure_packer()
13
14 return require('packer').startup(function(use)
15     use { 'wbthomason/packer.nvim' }
16     use({
17         'rose-pine/neovim',
18         as = 'rose-pine',
19         config = function()
20             vim.cmd('colorscheme rose-pine')
21         end
22     })
23     use { 'folke/tokyonight.nvim' }
24     use { 'unblevable/quick-scope'}
25     use { 'onsails/lspkind.nvim' }
26     use
27     {
28         'nvim-treesitter/nvim-treesitter',
29         run = ':TSUpdate'
30     }
31     use {
32         'VonHeikemen/lsp-zero.nvim',
33         requires = {
34             -- LSP Support
35             {'neovim/nvim-lspconfig'},
36             {'williamboman/mason.nvim'},
37             {'williamboman/mason-lspconfig.nvim'},
38
39             -- Autocompletion
40             {'hrsh7th/nvim-cmp'},
41             {'hrsh7th/cmp-buffer'},
42             {'hrsh7th/cmp-path'},
43             {'saadparwaiz1/cmp_luasnip'},
44             {'hrsh7th/cmp-nvim-lsp'},
45             {'hrsh7th/cmp-nvim-lua'},
46
47             -- Snippets
48             {'L3MON4D3/LuaSnip'},
49             {'rafamadriz/friendly-snippets'},
50
51
52             -- git 
53             { 'tpope/vim-fugitive' },
54         }
55     }
56
57     -- complition stuff
58     use { 'hrsh7th/cmp-cmdline' }
59
60     use {
61         'nvim-telescope/telescope.nvim', branch = '0.1.x',
62         requires = { {'nvim-lua/plenary.nvim'} }
63     }
64
65     -- Automatically set up configuration after cloning packer.nvim
66     if packer_bootstrap then
67         require('packer').sync()
68     end
69 end)