Os aliases do Mac OS são mais parecidos com os atalhos do Windows do que com os links simbólicos do Unix; você pode clicar duas vezes nelas, mas não pode cd
nelas.
Este artigo explica como fazer cd
dos aliases do OS X:
This is a two-part process requiring a little familiarity with gcc and bash, but I’ll try to make it as simple as possible. Firstly, you need this file: getTrueName.c. This file was created by Thos Davis and is licensed under the GPLv2. Save it anywhere, then compile it with the following command:
gcc -o getTrueName -framework Carbon getTrueName.c
This will create the ‘getTrueName’ executable in the same directory as the source. You can add it to your PATH, or just copy it directly to /usr/bin so it’s easy to access.
Interestingly, when Terminal opens a new shell, .bashrc is not executed as you might expect. Instead, under the login shell, .bash_profile is executed. So, add the following to .bash_profile in your Home directory. You might need to create it first; it isn’t there by default.
cd() { if [[ -f "$1" || -L "$1" ]]; then path=$(getTrueName "$1") builtin cd "$path" else builtin cd "$@" fi }
[edited the function a bit –grawity]