Re: not 'cd ..' , was Re: Wierd bug report: /usr/share/.. = / ???
Andrea Mennucc <debian@Tonelli.sns.it> writes:
> 'cd ..' is the wrong thing to do
> in bash , 'cd ..' takes away a directory from the `pwd`
> when `pwd` ends with a symlink, 'cd ..'
> do not bring into ..
> in that case, `ls ..` shows the 'real' parent, 'cd ..' brings into
> the 'convenience' parent
> whenever you have problems with symlinks, you should use 'realpath .'
> to know what is the real name of the current dir, and 'realpath ..'
> to know the real path name of ..
you can't assume realpath is installed (none of my systems (Potato,
Red Hat, Solaris) have it). explicitly avoiding the bash builtin by
writing /bin/pwd will give the correct result in a portable manner.
To UNSUBSCRIBE, email to email@example.com
with a subject of "unsubscribe". Trouble? Contact firstname.lastname@example.org