bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: New coreutil? realpath - retrieve canonicalized absolute path


From: P
Subject: Re: New coreutil? realpath - retrieve canonicalized absolute path
Date: Tue, 19 Jul 2005 10:15:24 +0100
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040124

Sebastian Rasmussen wrote:
> Below is a patch (against coreutils-cvs) that
> implements a new coreutil of mine, realpath, that
> more or less wraps the libc call realpath(3). This
> is done in order to allow shell scripts or users
> to retrieve an absolute path given a relative
> path.

What's wrong with the already-existing `readlink -f'?


Besides me not knowing that it existed, nothing.
It appears to give exactly the same results as
my realpath does. The manpage could state that
readlink performs canonicalization on links as
well as normal paths. That way I wouldn't have
missed it when searching for a suitable command.
Would a patch updating the manpage be suitable?

"How do I canonicalize a path" is a common question
in my experience, so making `readlink -f` better known
with documentation would help.
It would be great if `apropos canonicalize` returned it.

For the record I have `alias realpath='readlink -f'`.
Also FreeBSD has a realpath util as of 4.3

--
Pádraig Brady - http://www.pixelbeat.org
--




reply via email to

[Prev in Thread] Current Thread [Next in Thread]