1
1
Fork 0
mirror of https://github.com/schollz/croc.git synced 2025-10-11 13:21:00 +02:00

bash continues if autocompletion fails to install

Fixes #286
This commit is contained in:
Zack 2020-10-09 07:16:17 -07:00 committed by GitHub
parent 3396743d73
commit 5a2d51c060
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -725,16 +725,12 @@ main() {
print_message "== Installed autocompletions for $(basename "${SHELL}")" "ok"
elif [[ "${autocomplete_install_rcode}" == "1" ]]; then
print_message "== Failed to install ${bash_autocomplete_file}" "error"
exit 1
elif [[ "${autocomplete_install_rcode}" == "20" ]]; then
print_message "== Failed to locate 'install' command" "error"
exit 1
elif [[ "${autocomplete_install_rcode}" == "21" ]]; then
print_message "== Failed to locate 'sudo' command" "error"
exit 1
else
print_message "== Install attempt returned an unexpected value of ${autocomplete_install_rcode}" "error"
exit 1
fi
print_message "== Installation complete" "ok"