`
随便小屋
  • 浏览: 103020 次
  • 性别: Icon_minigender_1
  • 来自: 大连
社区版块
存档分类
最新评论

Ubuntu14.04系统Tab键不能自动补全问题解决

阅读更多

Unbuntu 14.4安装之后就在终端中使用Tab键不能自动补全,解决办法如下:

 

1、利用vi编辑器打开/etc/bash.bashrc文件(需要root权限)

sudo vi /etc/bash.bashrc

 接下来会提示输入密码

2、找到文件中的下列代码

#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]; then
#           . /etc/bash_completion
#      fi
#fi

 将注释符号#去掉,即改成

#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]; then
           . /etc/bash_completion
      fi
fi

 3、最后 source一下 /etc/bash.bashrc即可, 即

sudo source /etc/bash.bashrc

 

0
1
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics