summaryrefslogtreecommitdiffhomepage
path: root/.exrc
diff options
context:
space:
mode:
Diffstat (limited to '.exrc')
-rw-r--r--.exrc29
1 files changed, 28 insertions, 1 deletions
diff --git a/.exrc b/.exrc
index 109c044..65e0ff2 100644
--- a/.exrc
+++ b/.exrc
@@ -1,3 +1,30 @@
set tw=80
-nnoremap M :make -j8<CR>
+nnoremap M :make<CR>
+
+lua <<EOF
+local ls = require('luasnip')
+local fmt = require('luasnip.extras.fmt').fmt
+local f = ls.function_node
+local i = ls.insert_node
+local s = ls.s
+
+ls.add_snippets('gsp', {
+s('entry', fmt(
+ [[
+ __entry([<>], [
+ p {-
+ <>
+ }
+ ])
+ ]],
+ {
+ f(function() return os.date('%d-%m-%Y') end),
+ i(0),
+ },
+ {
+ delimiters = '<>',
+ }
+ ))
+})
+EOF