Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 27 lines (23 sloc) 0.696 kB
547f85d @aizatto Include ackrc
authored
1 # load rubygems and wirble
2 require 'rubygems' rescue nil
3 require 'wirble'
4
5 # load wirble
6 Wirble.init
7 Wirble.colorize
8
9 class Object
10 def methods_with_sort(filter = nil)
11 methods = methods_without_sort
12 if filter
13 filter = Regexp.new(filter.to_s, true) unless filter.is_a? Regexp
14 methods = methods.select { |method| method =~ filter }
15 end
16 methods.sort
17 end
18 alias_method :methods_without_sort, :methods
19 alias_method :methods, :methods_with_sort
20
21 def instance_variables_with_sort
22 instance_variables_without_sort.sort
23 end
24 alias_method :instance_variables_without_sort, :instance_variables
25 alias_method :instance_variables, :instance_variables_with_sort
26 end
Something went wrong with that request. Please try again.