commit | 1fa245bca1e1ca7443913a52b0e8e0bb465b5fe3 | [log] [tgz] |
---|---|---|
author | Kenny Root <kroot@google.com> | Tue May 03 19:33:06 2016 +0000 |
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | Tue May 03 19:33:06 2016 +0000 |
tree | 31d756de4e636cca46d2de870e0b3aef100052f1 | |
parent | 317031cb0035803f54c21cc78ea7cf830a247865 [diff] | |
parent | 77cab358b1dc292575b4dfbba0537ffcf6de82f4 [diff] |
Merge "adb completion: call _init_completion if available"
diff --git a/bash_completion/adb.bash b/bash_completion/adb.bash index 4b10e14..3017bfa 100644 --- a/bash_completion/adb.bash +++ b/bash_completion/adb.bash
@@ -16,13 +16,14 @@ # _adb() { - unset -v have - type $1 &> /dev/null && have="yes" - - if [ "$have" != "yes" ]; then + if ! type -t "$1" >/dev/null; then return fi + if type -t _init_completion >/dev/null; then + _init_completion || return + fi + local where i cur serial COMPREPLY=()