Write regular expressions to match...
$ alias rg="ruby /cs/www/classes/cs372/spring15/ruby/rgrep.rb" $ cal 9 2014 | rg 'YOUR-RE-HERE'
Note: There's a long story about the regular expressions recognized by grep and egrep. To keep focused on regular expressions as recognized by Ruby, I recommend using something simple like rgrep.rb, which provides a direct, simple way to use Ruby regular expressions. As a think-less rule, enclose regular expressions on the command line in single-quotes.
cat *.rb | rg 'YOUR-RE-HERE'Of course, rgrep.rb simply prints matching lines. You might augment it with something like show_match (slide 164) or something adapted from the example on slide 188, to name two possibilities.