am a8245d1d: Merge "ggrep" into klp-ub-dev

* commit 'a8245d1dc1746a8cd26aead8c15aa05c9b703455':
  ggrep
This commit is contained in:
Jon Boekenoogen
2014-04-09 09:27:33 +00:00
committed by Android Git Automerger

View File

@@ -10,6 +10,7 @@ Invoke ". build/envsetup.sh" from your shell to add the following functions to y
- mma: Builds all of the modules in the current directory, and their dependencies. - mma: Builds all of the modules in the current directory, and their dependencies.
- mmma: Builds all of the modules in the supplied directories, and their dependencies. - mmma: Builds all of the modules in the supplied directories, and their dependencies.
- cgrep: Greps on all local C/C++ files. - cgrep: Greps on all local C/C++ files.
- ggrep: Greps on all local Gradle files.
- jgrep: Greps on all local Java files. - jgrep: Greps on all local Java files.
- resgrep: Greps on all local res/*.xml files. - resgrep: Greps on all local res/*.xml files.
- godir: Go to the directory containing a file. - godir: Go to the directory containing a file.
@@ -1015,6 +1016,11 @@ function gettargetarch
get_build_var TARGET_ARCH get_build_var TARGET_ARCH
} }
function ggrep()
{
find . -name .repo -prune -o -name .git -prune -o -name out -prune -o -type f -name "*\.gradle" -print0 | xargs -0 grep --color -n "$@"
}
function jgrep() function jgrep()
{ {
find . -name .repo -prune -o -name .git -prune -o -name out -prune -o -type f -name "*\.java" -print0 | xargs -0 grep --color -n "$@" find . -name .repo -prune -o -name .git -prune -o -name out -prune -o -type f -name "*\.java" -print0 | xargs -0 grep --color -n "$@"