无法使kubectl bash完成在Mac上工作。我用brew安装了brew,即brew install bash-completion,然后按照安装说明将它添加到~/.bash_profile中
if [ -f $(brew --prefix)/etc/bash_completion ]; then . $(brew --prefix)/etc/bash_completion fi
但在重新获取配置文件后,仍然会得到错误的kubectl -bash: _init_completion: command not found。
发布于 2015-09-03 20:55:41
提供了一个补丁来解决kubectl的bash完成问题。您现在需要使用修补程序,如果您在osx上,直到PR被合并并再次来源bash完成,您还需要安装bash-completion,如上面的问题所述。
编辑:,它现在被合并成主控
https://stackoverflow.com/questions/32384452
复制相似问题