class Pry::Command::Ls::Grep
Public Class Methods
new(grep_regexp)
click to toggle source
# File lib/pry/commands/ls/grep.rb, line 7 def initialize(grep_regexp) @grep_regexp = grep_regexp end
Public Instance Methods
regexp()
click to toggle source
# File lib/pry/commands/ls/grep.rb, line 11 def regexp proc { |x| if x.instance_of?(Array) x.grep(@grep_regexp) else x =~ @grep_regexp end } end