summaryrefslogtreecommitdiffstats
path: root/lua/Snippets/tex/postfix.lua
diff options
context:
space:
mode:
authorNanderty <psopka@sopka.ch>2024-10-01 20:30:45 +0200
committerNanderty <psopka@sopka.ch>2024-10-01 20:30:45 +0200
commitf19424177c106b50b55939641826da43f554b830 (patch)
tree09d55515b38ef8fa0098f77247790d0f9e352282 /lua/Snippets/tex/postfix.lua
parent0fe818a2483ddc1232429c82af58a9e3111de1ec (diff)
downloadneovim-config-f19424177c106b50b55939641826da43f554b830.tar.gz
neovim-config-f19424177c106b50b55939641826da43f554b830.tar.bz2
neovim-config-f19424177c106b50b55939641826da43f554b830.zip
imporove LaTeX snippets
Diffstat (limited to 'lua/Snippets/tex/postfix.lua')
-rw-r--r--lua/Snippets/tex/postfix.lua33
1 files changed, 33 insertions, 0 deletions
diff --git a/lua/Snippets/tex/postfix.lua b/lua/Snippets/tex/postfix.lua
new file mode 100644
index 0000000..6cc071e
--- /dev/null
+++ b/lua/Snippets/tex/postfix.lua
@@ -0,0 +1,33 @@
+local helper = require('Snippets.luasniphelpers')
+
+return {
+
+ s({ trig = 'bgn', snippetType = 'autosnippet' },
+ fmta(
+ [[
+\lstinputlisting[
+ language = <>,
+ firstline = <>,
+ caption = {
+ <>
+ },
+]{<>}
+]],
+ {
+ i(1),
+ i(2),
+ i(3),
+ i(4),
+ }
+ ),
+ { condition = helper.line_begin }
+ ),
+
+ s({ trig = 'pbl', snippetType = 'autosnippet' },
+ {
+ t('\\printbibliography[heading=none]')
+ },
+ { condition = helper.line_begin }
+ ),
+
+}