Improve zsh 'up' alias

Rewrite the alias to compute the target directory and then use a single
`cd` comand to change directories. This makes it so that `cd -` commands
work properly to switch back to the previous directory. In addition,
running a command like `up 1000` will not take forever because of an
early escape condition that triggers when the root of the directory tree
is reached.