bash – expand shell variables ( bash bug resolved )

As you would have noticed in the recent versions of bash, expansion does not work properly when expanding directory names. So, for something like this

cd $varname

if you press tab, then variable name does not expand properly.

If this is something that is bothering you then you can now add the following in your bashrc and revert to older behaviour:

shopt -s direxpand

Hope this helps you.

About Amit Agarwal