feat: generate plugins/init.lua using fnl
This commit is contained in:
parent
8ff882a903
commit
8689c11dd0
3 changed files with 7 additions and 5 deletions
|
@ -24,7 +24,7 @@
|
||||||
;; autocmd, so it'll only apply to buffers you're interested in.
|
;; autocmd, so it'll only apply to buffers you're interested in.
|
||||||
;; Will use backslashes on Windows.
|
;; Will use backslashes on Windows.
|
||||||
;; Defaults to compiling all .fnl files, you may want to limit it to your fnl/ directory.
|
;; Defaults to compiling all .fnl files, you may want to limit it to your fnl/ directory.
|
||||||
:source-file-patterns [:./fnl/.*.fnl :./fnl/*.fnl :./fnl/**/*.fnl :init.fnl]
|
:source-file-patterns [:./fnl/.*.fnl :./fnl/*.fnl :./fnl/**/*.fnl :./init.fnl]
|
||||||
;; A function that is given the absolute path of a Fennel file and should return
|
;; A function that is given the absolute path of a Fennel file and should return
|
||||||
;; the equivalent Lua path, by default this will translate `fnl/foo/bar.fnl` to `lua/foo/bar.lua`.
|
;; the equivalent Lua path, by default this will translate `fnl/foo/bar.fnl` to `lua/foo/bar.lua`.
|
||||||
;; See the "Writing Lua elsewhere" tip below for an example function that writes to a sub directory.
|
;; See the "Writing Lua elsewhere" tip below for an example function that writes to a sub directory.
|
||||||
|
|
3
fnl/plugins/init.fnl
Normal file
3
fnl/plugins/init.fnl
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
(vim.loader.enable)
|
||||||
|
(let [plugins (require :plugins.lz-spec)]
|
||||||
|
((. (require :lz.n) :load) plugins))
|
|
@ -1,5 +1,4 @@
|
||||||
-- Experimental Neovim byte-compiled module loader
|
-- [nfnl] Compiled from ./fnl/plugins/init.fnl by https://github.com/Olical/nfnl, do not edit.
|
||||||
vim.loader.enable()
|
vim.loader.enable()
|
||||||
|
local plugins = require("plugins.lz-spec")
|
||||||
local pluginSpec = require("plugins.lz-spec")
|
return require("lz.n").load(plugins)
|
||||||
require("lz.n").load(pluginSpec)
|
|
||||||
|
|
Loading…
Reference in a new issue