Created
January 29, 2013 13:37
-
-
Save deepak/4664291 to your computer and use it in GitHub Desktop.
match a word in grep or ack
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| age=10 | |
| age=11 | |
| age = 12 | |
| age=13 | |
| hello. age = 14 | |
| message = "hello" |
Author
Author
note to future self: have more descriptive variable names
Author
for Rails, came up with:
function rails_ack() {
# ack -w $1 db/ app/ config/ lib/ public/
ack -w --ruby --html --rake --ignore-dir=doc --ignore-dir=log $1 .
}
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
% ack -w age /tmp/test.txt
age=10
age=11
age = 12
age=13
hello. age = 14