9.10 only tab complete adding a space and no /
i use tab complete all the time.
on 9.04 if you start typing the name of a directory then hit tab you get somthing like this
Code:
cd Doc<tab>
cd Documents/
this immidiatly lets you type the first few letters of the subdir you want and use tab again....
on 9.10 this has changed so you get the name of the dir
but with a space after and no slash
this means you end up typing, a few letters, a tab, a backspace a slash, some more letters, another tab, another backspace another slash, etc etc.
this is very annoying ](*,)
how do i change it back to the old behaviour?
Re: 9.10 only tab complete adding a space and no /
This is not a problem with 9.10. It sounds like you somehow messed up your bashrc file or bash is not being loaded. When you open a terminal type
and hit enter. If this doesn't solve your problem post your ~/.bashrc file here.
Re: 9.10 only tab complete adding a space and no /
yes, starting bash manually from in a terminal fixes the problem,
i havent yet set anything in my .bashrc but there appears to be a load of default stuff in there!
Code:
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
[ -z "$PS1" ] && return
# don't put duplicate lines in the history. See bash(1) for more options
# don't overwrite GNU Midnight Commander's setting of `ignorespace'.
HISTCONTROL=$HISTCONTROL${HISTCONTROL+,}ignoredups
# ... or force ignoredups and ignorespace
HISTCONTROL=ignoreboth
# append to the history file, don't overwrite it
shopt -s histappend
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# make less more friendly for non-text input files, see lesspipe(1)
[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
# set variable identifying the chroot you work in (used in the prompt below)
if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
# set a fancy prompt (non-color, unless we know we "want" color)
case "$TERM" in
xterm-color) color_prompt=yes;;
esac
# uncomment for a colored prompt, if the terminal has the capability; turned
# off by default to not distract the user: the focus in a terminal window
# should be on the output of commands, not on the prompt
#force_color_prompt=yes
if [ -n "$force_color_prompt" ]; then
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
# We have color support; assume it's compliant with Ecma-48
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
# a case would tend to support setf rather than setaf.)
color_prompt=yes
else
color_prompt=
fi
fi
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
;;
*)
;;
esac
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
alias ls='ls --color=auto'
#alias dir='dir --color=auto'
#alias vdir='vdir --color=auto'
alias grep='grep --color=auto'
alias fgrep='fgrep --color=auto'
alias egrep='egrep --color=auto'
fi
# some more ls aliases
#alias ll='ls -l'
#alias la='ls -A'
#alias l='ls -CF'
# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
if [ -f /etc/bash_completion ] && ! shopt -oq posix; then
. /etc/bash_completion
fi
Re: 9.10 only tab complete adding a space and no /
Quote:
Originally Posted by
dasy2k1
yes, starting bash manually from in a terminal fixes the problem,
It sounds like your default shell has somehow been changed to something other than bash. Here's a tutorial (just google'd for it) to change your default shell back to bash.
Re: 9.10 only tab complete adding a space and no /
nope, its definaltly bash
echo $SHELL
reports to be /bin/bash
and /ect/passwd has bash set as default shell
strangely now its working with cd
but not with other commads
eg
ssh -i .ss<tab> still gives a space after the dir
Re: 9.10 only tab complete adding a space and no /
Just encounter the same problem and search around, the strange behaviour is caused by some code in /etc/bash_completion, following is what I have done and hope it's useful.
1: backup
sudo cp /etc/bash_completion /etc/bash_completion.bak
2: edit
sudo vi /etc/bash_completion
3: find and comment following code (around line 1576, 93%):
for i in a2ps awk bash bc bison cat colordiff cp csplit \
curl cut date df diff dir du enscript env expand fmt fold gperf gprof \
grep grub head indent irb ld ldd less ln ls m4 md5sum mkdir mkfifo mknod \
mv netstat nl nm objcopy objdump od paste patch pr ptx readelf rm rmdir \
sed seq sha{,1,224,256,384,512}sum shar sort split strip tac tail tee \
texindex touch tr uname unexpand uniq units vdir wc wget who; do
have $i && complete -F _longopt -o default $i
done
unset i
4: close all terminals and open a new one, then give a try:).
Re: 9.10 only tab complete adding a space and no /
this actually works, thank you so much!
Re: 9.10 only tab complete adding a space and no /
Thanks alot! That did it!
Re: 9.10 only tab complete adding a space and no /
Thanks also for your help!! Tab-completion works again :D
Re: 9.10 only tab complete adding a space and no /
This worked for me too - thanks! I was having issues in 11.10