symtools
Software
www.skarnet.org
The linkname program
linkname is a trivial rewrite of the Debian GNU/Linux
readlink command.
Interface
linkname [ -n ] [ -f ] link
performs a readlink(2) system call on link and writes the
result on stdout.
Options
- -n : do not print a newline after the result.
- -f : use realpath(3) instead of readlink(2).
Rationale
Why is there no readlink by default for other Linux distributions than
Debian ? Why are the useful -n and -f options
absent from readlink in other Unices ? Now you have a
nice, portable and small readlink utility.
Since it preexisted to /package,
the readlink name could not be registered in
/command. So I decided to write
such a command without exporting it; at the same time,
Balazs Nagy did the same but called it
linkname, and registered it in /command. Then we agreed to
eliminate redundancy: there is only one readlink-like command,
it's called linkname, it's registered in /command,
and it belongs to the admin/symtools package.