打开终端:
sudo gedit /etc/bash.bashrc
将这个文件一下内容注释去掉。
enable bash completion in interactive shells
if ! shopt -oq posix; then
if [ -f /usr/share/bash-completion/bash_completion ]; then
. /usr/share/bash-completion/bash_completion
elif [ -f /etc/bash_completion ];
. /etc/bash_completion
fi
fi