Make verifymodinfo in envsetup.sh quiet on errors during tab completion
Test: m <tab><tab> before having done a full build. Test: m <tab><tab> after having done a full build. Change-Id: I35154151e6902d0337a26eab27d9d4fc797beed7
This commit is contained in:
parent
4acbe3b416
commit
0bac4fe09d
|
@ -1458,13 +1458,17 @@ function refreshmod() {
|
||||||
# Verifies that module-info.txt exists, creating it if it doesn't.
|
# Verifies that module-info.txt exists, creating it if it doesn't.
|
||||||
function verifymodinfo() {
|
function verifymodinfo() {
|
||||||
if [ ! "$ANDROID_PRODUCT_OUT" ]; then
|
if [ ! "$ANDROID_PRODUCT_OUT" ]; then
|
||||||
|
if [ "$QUIET_VERIFYMODINFO" != "true" ] ; then
|
||||||
echo "No ANDROID_PRODUCT_OUT. Try running 'lunch' first." >&2
|
echo "No ANDROID_PRODUCT_OUT. Try running 'lunch' first." >&2
|
||||||
|
fi
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -f "$ANDROID_PRODUCT_OUT/module-info.json" ]; then
|
if [ ! -f "$ANDROID_PRODUCT_OUT/module-info.json" ]; then
|
||||||
|
if [ "$QUIET_VERIFYMODINFO" != "true" ] ; then
|
||||||
echo "Could not find module-info.json. It will only be built once, and it can be updated with 'refreshmod'" >&2
|
echo "Could not find module-info.json. It will only be built once, and it can be updated with 'refreshmod'" >&2
|
||||||
refreshmod || return 1
|
fi
|
||||||
|
return 1
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1602,7 +1606,7 @@ function installmod() {
|
||||||
|
|
||||||
function _complete_android_module_names() {
|
function _complete_android_module_names() {
|
||||||
local word=${COMP_WORDS[COMP_CWORD]}
|
local word=${COMP_WORDS[COMP_CWORD]}
|
||||||
COMPREPLY=( $(allmod | grep -E "^$word") )
|
COMPREPLY=( $(QUIET_VERIFYMODINFO=true allmod | grep -E "^$word") )
|
||||||
}
|
}
|
||||||
|
|
||||||
# Print colored exit condition
|
# Print colored exit condition
|
||||||
|
|
Loading…
Reference in New Issue