79 lines
2.1 KiB
Fennel
79 lines
2.1 KiB
Fennel
(local nvim (require :aniseed.nvim))
|
|
(local core (require :aniseed.core))
|
|
(local util (require :config.util))
|
|
|
|
(lambda plug [coord ?opts]
|
|
"Defines a plugin through vim-plug."
|
|
(if (= opts nil)
|
|
(nvim.fn.plug# coord)
|
|
(nvim.fn.plug# coord opts)))
|
|
|
|
(fn known-plugin? [candidate]
|
|
"Returns true if the given name can be found within any of the required
|
|
plugin names. So `deoplete` would match `deoplete.nvim`."
|
|
(or (. nvim.g.plugs candidate)
|
|
(->> (core.keys nvim.g.plugs)
|
|
(core.some
|
|
(fn [plug-name]
|
|
(plug-name:find candidate 1 true))))))
|
|
|
|
;; Set up vim-plug, like in init.vim earlier.
|
|
(nvim.fn.plug#begin (.. (nvim.fn.stdpath "data") "/plugged"))
|
|
|
|
;; This is in init.vim but if it's not here too sync.sh will delete it.
|
|
; (plug "Olical/aniseed")
|
|
(plug "Olical/aniseed" {:branch :develop})
|
|
|
|
(plug "inkarkat/vim-ReplaceWithRegister")
|
|
(plug "chriskempson/base16-vim")
|
|
|
|
;; LSP Stuff
|
|
(plug "williamboman/mason.nvim")
|
|
(plug "williamboman/mason-lspconfig.nvim")
|
|
(plug "neovim/nvim-lspconfig")
|
|
|
|
;; Lisp-in-lua
|
|
(plug "Olical/conjure")
|
|
(plug "bakpakin/fennel.vim")
|
|
|
|
(plug "ctrlpvim/ctrlp.vim")
|
|
|
|
;; Usable dispatch
|
|
(plug "tpope/vim-dispatch")
|
|
(plug "radenling/vim-dispatch-neovim")
|
|
|
|
;; Follow symlinks
|
|
(plug "moll/vim-bbye")
|
|
(plug "aymericbeaumet/vim-symlink")
|
|
|
|
;; Respect editorconfig
|
|
(plug "gpanders/editorconfig.nvim")
|
|
|
|
(plug "terryma/vim-expand-region")
|
|
|
|
|
|
;; TODO CONFIGURE
|
|
(plug "nvim-treesitter/nvim-treesitter" {:do ":TSUpdate"})
|
|
(plug "https://git.sr.ht/~p00f/nvim-ts-rainbow")
|
|
|
|
;; TODO CONFIGURE
|
|
(plug "datwaft/bubbly.nvim")
|
|
|
|
(plug "tpope/vim-fugitive")
|
|
(plug "mhinz/vim-signify")
|
|
(plug "tpope/vim-commentary")
|
|
(plug "mbbill/undotree")
|
|
(plug "folke/which-key.nvim")
|
|
(plug "airblade/vim-rooter")
|
|
|
|
;; Define all required plugins.
|
|
(nvim.fn.plug#end)
|
|
|
|
;; Load plugin configuration modules.
|
|
(core.run!
|
|
(fn [path]
|
|
(let [name (nvim.fn.fnamemodify path ":t:r")]
|
|
(if (known-plugin? name)
|
|
(require (.. "config.module.plugin." name))
|
|
(print (.. "Orphan plugin configuration: " name)))))
|
|
(util.glob (.. (nvim.fn.stdpath "config") "/lua/config/module/plugin/*.lua")))
|