I'm using Terminal Version 2.2.3 (303.2).
The problem is when I try to change directory starting from root, I have to double tab for some directories to get trailing slash.
For example, I start to type
cd /et
Tab
it gives me:
/etc
Then I have to hit tab once more to get needed trailing slash
/etc/
And then, finally, I can Tab all further directories using single tab hit.
How can I fix this? I miss Ubuntu's bash so much.
Best Answer
This is because, on OS X,
/etc
is a symbolic link:that is,
/etc
is a file, not a directory.If you try a real directory, like
/usr
, you'll see the expected behavior:You can force Bash to treat symlinked directories as directories with this command:
Add it to your
.bashrc
and source it (that is, read and execute commands from it) like this:or reopen Terminal.