Bash programmable completion of variable names

PleegWat pleegwat at telfort.nl
Mon Jun 22 17:25:52 UTC 2009


Hal Burgiss wrote:
> I have a number of Ubuntu systems. On just one the tab expansion of shell
> variables does not "work" as expected. Other types of completion work just
> fine. And on all the other systems, tab completion of variables works fine.
> For the life of me I cannot find where/how to turn this aspect on. I find
> plenty of references of this on google, but not really troubleshooting type
> help.
> 
> So on all systems except one, 
> 
>  cd $c/<TAB> ... expands to 
>  cd /var/system/clients
> 
> on the problem system I get:
> 
>  cd $c/<TAB>
>  cd \$c
> 
> $c is defined identically on all systems.

I'm not quite able to reproduce either behaviour. Does a file/directory 
whose name starts with '$c' exist in the current working directory, or 
is CDPATH set and does a directory with such name exist in a directory 
in CDPATH?

PleegWat




More information about the ubuntu-users mailing list