diff --git a/UltiSnips/ruby.snippets b/UltiSnips/ruby.snippets index 6114cfa..b8a0092 100644 --- a/UltiSnips/ruby.snippets +++ b/UltiSnips/ruby.snippets @@ -302,18 +302,6 @@ begin end while ${1:expression} endsnippet -snippet "\b(r|attr)" "attr_reader :" r -attr_reader :${0:attr_names} -endsnippet - -snippet "\b(w|attr)" "attr_writer :" r -attr_writer :${0:attr_names} -endsnippet - -snippet "\b(rw|attr)" "attr_accessor :" r -attr_accessor :${0:attr_names} -endsnippet - snippet begin "begin ... rescue ... end" begin $1 diff --git a/snippets/ruby.snippets b/snippets/ruby.snippets index c4bcc43..22878c3 100644 --- a/snippets/ruby.snippets +++ b/snippets/ruby.snippets @@ -121,23 +121,17 @@ snippet cla class .. initialize .. end ${0} end end -snippet cla class .. < ParentClass .. initialize .. end +snippet cla< class .. < ParentClass .. initialize .. end class ${1:`substitute(vim_snippets#Filename(), '\(_\|^\)\(.\)', '\u\2', 'g')`} < ${2:ParentClass} def initialize(${3:args}) ${0} end end -snippet cla ClassName = Struct .. do .. end - ${1:`substitute(vim_snippets#Filename(), '\(_\|^\)\(.\)', '\u\2', 'g')`} = Struct.new(:${2:attr_names}) do - def ${3:method_name} - ${0} - end - end -snippet cla class BlankSlate .. initialize .. end +snippet blankslate class BlankSlate .. initialize .. end class ${0:BlankSlate} instance_methods.each { |meth| undef_method(meth) unless meth =~ /\A__/ } end -snippet cla class << self .. end +snippet claself class << self .. end class << ${1:self} ${0} end @@ -152,12 +146,6 @@ snippet cla- end snippet mod module .. end module ${1:`substitute(vim_snippets#Filename(), '\(_\|^\)\(.\)', '\u\2', 'g')`} - ${0} - end -snippet mod module .. module_function .. end - module ${1:`substitute(vim_snippets#Filename(), '\(_\|^\)\(.\)', '\u\2', 'g')`} - module_function - ${0} end snippet mod module .. ClassMethods .. end