From f1eabbaa1b4ff1836d0ee8335b31d009203f3775 Mon Sep 17 00:00:00 2001 From: "Vito G. Graffagnino" Date: Tue, 30 Aug 2022 16:06:22 +0100 Subject: fixed zathura integration with texlab using nvim-texlabconfig --- luasnip_snippets/ruby.json | 111 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 111 insertions(+) create mode 100644 luasnip_snippets/ruby.json (limited to 'luasnip_snippets/ruby.json') diff --git a/luasnip_snippets/ruby.json b/luasnip_snippets/ruby.json new file mode 100644 index 0000000..6c24630 --- /dev/null +++ b/luasnip_snippets/ruby.json @@ -0,0 +1,111 @@ +{ + "#!": { + "prefix": "#!", + "description": "#!/usr/bin/env ruby", + "body": [ + "#!/usr/bin/env ruby", + "$0" + ], + "luasnip": { + "priority": -50 + } + }, + "defr": { + "prefix": "defr", + "description": "def ... rescue ...", + "body": [ + "def ${1:function_name}${2:(${3:*args})}", + "\t$4", + "rescue", + "\t$0", + "end" + ] + }, + "For": { + "prefix": "For", + "description": "(..).each { || }", + "body": "(${1:from}..${2:to}).each { |${3:i}| $0 \\}" + }, + "until": { + "prefix": "until", + "description": "until ... end", + "body": [ + "until ${1:expression}", + "\t$0", + "end" + ] + }, + "Until": { + "prefix": "Until", + "description": "begin ... end until ", + "body": [ + "begin", + "\t$0", + "end until ${1:expression}" + ] + }, + "while": { + "prefix": "while", + "description": "while ... end", + "body": [ + "while ${1:expression}", + "\t$0", + "end" + ] + }, + "While": { + "prefix": "While", + "description": "begin ... end while ", + "body": [ + "begin", + "\t$0", + "end while ${1:expression}" + ] + }, + "begin": { + "prefix": "begin", + "description": "begin ... rescue ... end", + "body": [ + "begin", + "\t$1", + "rescue", + "\t$0", + "end" + ] + }, + "rescue": { + "prefix": "rescue", + "body": [ + "rescue Exception => e", + "\tputs e.message", + "\tputs e.backtrace.inspect", + "\t${0:# Rescue}" + ] + }, + "###": { + "prefix": "###", + "body": [ + "=begin", + "\t$0", + "=end" + ] + }, + "priv": { + "prefix": "priv", + "description": "private ", + "body": [ + "private", + "", + "$0" + ] + }, + "prot": { + "prefix": "prot", + "description": "protected", + "body": [ + "protected", + "", + "$0" + ] + } +} -- cgit v1.2.3