Merge "add argument error handling to grep-all.sh"

This commit is contained in:
Zuul 2018-01-23 12:15:11 +00:00 committed by Gerrit Code Review
commit 0218f7be62
1 changed files with 6 additions and 0 deletions

View File

@ -17,6 +17,12 @@
declare -a branches=($(git describe --always) origin/master)
branches+=($(git branch --no-color -r --list 'origin/stable/*'))
if [ $# -ne 1 ]; then
echo "Usage: $0 dependency-name" 1>&2
exit 1
fi
function search {
git grep -hEi "^${1}[=><!]" ${2} -- "${3}"
}