dotfiles/.config/nvim/snippets/asciidoc.lua

20 lines
558 B
Lua

local s = require("luasnip.nodes.snippet").S
local i = require("luasnip.nodes.insertNode").I
local fmt = require("luasnip.extras.fmt").fmt
return {
s({ trig = 'source',
name = 'source code block',
dscr = 'Insert a source code block'
},
fmt([[
[source,{language}]
--------------------------------------------------------------------------------
{cursor}
--------------------------------------------------------------------------------
]] , {
language = i(1, 'shell'),
cursor = i(0)
}))
}