From ba5fc8e59397ff2d986681457ed590742ce522e8 Mon Sep 17 00:00:00 2001 From: Alex Klyubin Date: Mon, 6 May 2013 14:11:48 -0700 Subject: [PATCH] sepgrep -- function to grep SELinux policy files. Change-Id: Ib86a124296ecbc2b2ce9a0323c40c85ceb6cd466 --- envsetup.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/envsetup.sh b/envsetup.sh index 63a29e918..70cb2de75 100644 --- a/envsetup.sh +++ b/envsetup.sh @@ -882,6 +882,11 @@ function mangrep() find . -name .repo -prune -o -name .git -prune -o -path ./out -prune -o -type f -name 'AndroidManifest.xml' -print0 | xargs -0 grep --color -n "$@" } +function sepgrep() +{ + find . -name .repo -prune -o -name .git -prune -o -path ./out -prune -o -name sepolicy -type d -print0 | xargs -0 grep --color -n -r --exclude-dir=\.git "$@" +} + case `uname -s` in Darwin) function mgrep()