summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGustaf Rydholm <gustaf.rydholm@gmail.com>2024-05-15 01:33:26 +0200
committerGustaf Rydholm <gustaf.rydholm@gmail.com>2024-05-15 01:33:26 +0200
commit8760754a8229465308c97d992897ed5fc23df667 (patch)
tree0cb6c599091a391bfbd276e97429aecb4039a8ca
parentc2dcd4d897efdb475451a8a10d7085aa9a1f097e (diff)
Revert 1 commits
c2dcd4d 'Update loading of plugins'
-rw-r--r--fnl/aktersnurra.fnl12
1 files changed, 11 insertions, 1 deletions
diff --git a/fnl/aktersnurra.fnl b/fnl/aktersnurra.fnl
index 00367be..e8106d5 100644
--- a/fnl/aktersnurra.fnl
+++ b/fnl/aktersnurra.fnl
@@ -1,4 +1,14 @@
;; Load plugins with lazy.
+
+(local plugins (let [plugins []
+ path (.. (vim.fn.stdpath :config) :/fnl/plugins)]
+ (each [fname (vim.fs.dir path)]
+ (let [fname (fname:match "^(.*)%.fnl$")]
+ (if (not= fname nil)
+ (table.insert plugins (require (.. :plugins. fname))))))
+ (table.insert plugins (require :plugins.lsp))
+ plugins))
+
(local icons (require :settings.icons))
(local opts {:install {:colorscheme [:no-clown-fiesta]}
@@ -38,6 +48,6 @@
(require :settings)
(let [lazy (require :lazy)]
(vim.keymap.set :n :<leader>y "<cmd>Lazy home<cr>" {:desc :Home})
- (lazy.setup {:import :plugins} opts)))
+ (lazy.setup plugins opts)))
(init)