1
Fork 0

Start working on a more modern latex snippet system

This commit is contained in:
prescientmoon 2024-03-14 07:48:19 +01:00
parent b0ff2979ed
commit a47be3adf9
Signed by: prescientmoon
SSH key fingerprint: SHA256:UUF9JT2s8Xfyv76b8ZuVL7XrmimH4o49p4b+iexbVH4
5 changed files with 283 additions and 190 deletions
home/features/neovim

View file

@ -846,20 +846,26 @@ let
# {{{ luasnip
# snippeting engine
luasnip =
let reload = /* lua */ ''require("luasnip.loaders.from_vscode").lazy_load()'';
let reloadVscode = /* lua */ ''require("luasnip.loaders.from_vscode").lazy_load()'';
in
{
package = "L3MON4D3/LuaSnip";
version = "v2";
cond = blacklist "vscode";
config = thunk reload;
config = thunk ''
require("luasnip").config.setup(${encode {
enable_autosnippets = true;
update_events = ["TextChanged" "TextChangedI"];
}})
${reloadVscode}
'';
# {{{ Keybinds
keys = [
{
mapping = "<leader>rs";
action = thunk reload;
action = thunk reloadVscode;
desc = "[R]eload [s]nippets";
}
{