Skip to content

Instantly share code, notes, and snippets.

@stopdropandrew
Created April 14, 2011 23:51
Show Gist options
  • Save stopdropandrew/920854 to your computer and use it in GitHub Desktop.
Save stopdropandrew/920854 to your computer and use it in GitHub Desktop.
alias oops="rfind breakpoint; rfind debugger"
function rfindhelper () {
find $1 -name '*.rb' -o -name '*.rhtml' -o -name '*.erb' -o -name '*.rjs' -o -name '*.builder' -o -name '*.js' | xargs grep -i "$2"
}
function rfind () {
rfindhelper "app config test lib" "$*"
}
function rfindrails () {
rfindhelper "vendor/rails" "$*"
}
function rfinddir () {
rfindhelper $1 "$2"
}
function rfindas () { find "lib/flash" -name *.as | xargs grep -i "$*" ;}
function rfindjs () { find "public/javascripts" -name *.js | xargs grep -i "$*" ;}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment