android : add autocomplete for emulators.

This commit is contained in:
Dmitry Voronin 2023-12-13 22:21:09 +03:00
parent 944e651b7d
commit e6654e66ab

View file

@ -8,3 +8,9 @@ function emulator() {
${ANDROID_SDK_ROOT}/emulator/emulator -avd "${name}" &> /dev/null & disown
}
function _android_emulators() {
_autocomplete_first $(ls --classify .android/avd/ | grep \/$ | sed -e "s/.avd\/$//")
}
complete -F _android_emulators emulator