2023-02-18 23:34:09 +01:00
|
|
|
(vim.cmd "packadd packer.nvim")
|
|
|
|
|
2023-05-19 17:38:42 +02:00
|
|
|
(local packer (require :packer))
|
|
|
|
|
2023-02-18 23:34:09 +01:00
|
|
|
(macro pconf [plugin]
|
2023-02-19 21:28:57 +01:00
|
|
|
`#(require ,(.. :pluginconf.p- plugin)))
|
2023-02-18 23:34:09 +01:00
|
|
|
|
|
|
|
(macro use/pconf [use plugin conf]
|
|
|
|
`(,use {1 ,plugin :config (pconf ,conf)}))
|
|
|
|
|
|
|
|
(macro use/pconf [use plugin conf extra]
|
|
|
|
(var c {1 plugin :config `(pconf ,conf)})
|
|
|
|
(when (table? extra)
|
|
|
|
(each [k v (pairs extra)]
|
|
|
|
(tset c k v)))
|
|
|
|
`(,use ,c))
|
|
|
|
|
|
|
|
(fn cmp-plugins [use]
|
|
|
|
(use/pconf use :neovim/nvim-lspconfig :lspconf)
|
2023-02-19 21:28:57 +01:00
|
|
|
(use/pconf use :hrsh7th/nvim-cmp :cmp)
|
2023-02-18 23:34:09 +01:00
|
|
|
(use :hrsh7th/cmp-nvim-lsp)
|
|
|
|
(use :hrsh7th/cmp-buffer)
|
|
|
|
(use :hrsh7th/cmp-path)
|
|
|
|
(use :hrsh7th/cmp-cmdline)
|
|
|
|
(use :saadparwaiz1/cmp_luasnip)
|
2023-02-19 21:28:57 +01:00
|
|
|
(use/pconf use :L3MON4D3/LuaSnip :luasnip
|
2023-02-18 23:34:09 +01:00
|
|
|
{:requires :rafamadriz/friendly-snippets})
|
|
|
|
(use {1 :Saecki/crates.nvim :config #((. (require :crates) :setup) {})})
|
|
|
|
(use :ray-x/cmp-treesitter)
|
|
|
|
(use/pconf use :jose-elias-alvarez/null-ls.nvim :nullls)
|
|
|
|
(use {1 :LhKipp/nvim-nu
|
2023-02-23 10:56:20 +01:00
|
|
|
:config #((. (require :nu) :setup) {:complete_cmd_names true})})
|
|
|
|
(use :PaterJason/cmp-conjure))
|
2023-02-18 23:34:09 +01:00
|
|
|
|
|
|
|
(fn init [use]
|
|
|
|
(use :wbthomason/packer.nvim)
|
2023-06-08 20:16:50 +02:00
|
|
|
(use {1 :catppuccin/nvim :as :catppuccin})
|
2023-02-18 23:34:09 +01:00
|
|
|
(use {1 :lewis6991/gitsigns.nvim
|
|
|
|
:config #((. (require :gitsigns) :setup) {})})
|
|
|
|
(use :dag/vim-fish)
|
|
|
|
(use/pconf use :nvim-lualine/lualine.nvim :line)
|
|
|
|
(use/pconf use :nvim-treesitter/nvim-treesitter :treesitter)
|
2023-02-19 21:28:57 +01:00
|
|
|
(use/pconf use :nvim-tree/nvim-web-devicons :devicons)
|
2023-02-18 23:34:09 +01:00
|
|
|
(use/pconf use :nvim-tree/nvim-tree.lua :nvimtree
|
|
|
|
{:requires :nvim-tree/nvim-web-devicons})
|
2023-02-19 21:28:57 +01:00
|
|
|
(use/pconf use :TimUntersberger/neogit :neogit
|
2023-02-18 23:34:09 +01:00
|
|
|
{:requires :nvim-lua/plenary.nvim})
|
|
|
|
(use/pconf use :nvim-telescope/telescope.nvim :telescope
|
|
|
|
{:requires :nvim-lua/plenary.nvim})
|
|
|
|
(use/pconf use :windwp/nvim-autopairs :autopairs)
|
|
|
|
(use :windwp/nvim-ts-autotag)
|
|
|
|
(use/pconf use :HiPhish/nvim-ts-rainbow2 :tsrainbow2)
|
|
|
|
(use/pconf use :akinsho/toggleterm.nvim :tterm)
|
|
|
|
(use :DingDean/wgsl.vim)
|
|
|
|
(use :rcarriga/nvim-notify)
|
2023-05-14 19:14:25 +02:00
|
|
|
;; TODO: remove once noice gets support for ui.select
|
|
|
|
(use {1 :stevearc/dressing.nvim
|
|
|
|
:config #((. (require :dressing) :setup) {:input ;; Provided by noice
|
|
|
|
{:enabled false}})})
|
2023-02-18 23:34:09 +01:00
|
|
|
(use/pconf use :nvim-treesitter/nvim-treesitter-context :ts-context)
|
|
|
|
(use :DaeZak/crafttweaker-vim-highlighting)
|
|
|
|
(use :mfussenegger/nvim-jdtls)
|
2023-02-19 21:28:57 +01:00
|
|
|
(use/pconf use :kevinhwang91/nvim-ufo :ufo
|
2023-02-18 23:34:09 +01:00
|
|
|
{:requires :kevinhwang91/promise-async :after :nvim-lspconfig})
|
2023-02-19 21:28:57 +01:00
|
|
|
(use/pconf use :stevearc/aerial.nvim :aerial)
|
2023-02-21 21:42:55 +01:00
|
|
|
(use/pconf use :mfussenegger/nvim-dap :dap {:requires :rcarriga/nvim-dap-ui})
|
2023-02-19 21:28:57 +01:00
|
|
|
(use/pconf use :ThePrimeagen/harpoon :harpoon)
|
|
|
|
(use/pconf use :chrisgrieser/nvim-recorder :recorder)
|
2023-05-14 19:14:25 +02:00
|
|
|
(use/pconf use :folke/noice.nvim :noice {:requires :MunifTanjim/nui.nvim})
|
2023-02-18 23:34:09 +01:00
|
|
|
(use :jdonaldson/vaxe)
|
2023-02-21 21:42:55 +01:00
|
|
|
(use/pconf use :CKolkey/ts-node-action :tsn-actions
|
|
|
|
{:requires :jose-elias-alvarez/null-ls.nvim})
|
|
|
|
(use :nvim-treesitter/playground)
|
2023-03-28 00:39:38 +02:00
|
|
|
(use {1 :Olical/conjure :setup (pconf :conjure)})
|
2023-02-18 23:34:09 +01:00
|
|
|
(cmp-plugins use))
|
|
|
|
|
2023-05-19 17:38:42 +02:00
|
|
|
(packer.startup init)
|
|
|
|
|
|
|
|
;; PackerCompile automagically
|
|
|
|
(when (= 0 (length (vim.api.nvim_get_runtime_file :plugin/packer_compiled.lua
|
|
|
|
false)))
|
|
|
|
(packer.compile))
|
2023-02-18 23:34:09 +01:00
|
|
|
|
|
|
|
;; actually compile packer-generated config after packer's "compile" step
|
|
|
|
(fn compile-packer-generated []
|
|
|
|
(let [mztenv (require :mzte_nv)
|
|
|
|
packer (require :packer)]
|
|
|
|
(mztenv.compile.compilePath packer.config.compile_path)))
|
|
|
|
|
|
|
|
(vim.api.nvim_create_autocmd :User
|
|
|
|
{:pattern :PackerCompileDone
|
|
|
|
:once true
|
|
|
|
:callback compile-packer-generated})
|