neosnippet.vim/autoload/neocomplcache/sources/snippets_complete/ruby.snip
2012-09-22 22:55:13 -07:00

51 lines
721 B
Plaintext

snippet if
abbr if end
if ${1:condition}
${2}
end
snippet def
abbr def end
def ${1:method_name}
${2}
end
snippet do
abbr do end
do
${1}
end
snippet dovar
abbr do |var| end
do |${1:var}|
${2}
end
snippet block
abbr { }
{
${1}
}
snippet blockvar
abbr {|var| }
{|${1:var}|
${2}
}
snippet fileopen
abbr File.open(filename) do end
File.open(${1:filename}, '${2:w}') do |${3:io}|
${0}
end
snippet edn
abbr => end?
end
snippet urlencode
# coding: utf-8
require 'erb'
puts ERB::Util.url_encode '${1}'