Command completion for Kafka tools and bin commands
- Source the files for use or place these inside your shell profile like: ~/.bash_profile or ~/.bashrc:
source ./kafkaAdmin
source ./kafkaBin
- Complete for Admin tools is by typing: kafka-run-class.sh [TAB][TAB]
- Complete for bin tools by typing (using zookeeper-security-migration for an example): bin/zookeeper-security-migration.sh --[TAB][TAB]
- StackOverflow Q/A
- Notice the answers explaining the following:
autoload -U compinit && compinit
autoload -U bashcompinit && bashcompinit
source /path/bash_completion_script