READLINK(1)

NAME
readlink - print symbolic link targets or canonical file names

SYNOPSIS
readlink [OPTION...] [path...]

DESCRIPTION
The readlink utility by default reads and prints symbolic link names. It can additionally canonicalize paths, but in general realpath should be preferred for that.

The options are as follows:

-f, -e, --canonicalize, --canonicalize-existing
    Instead of reading link target, canonicalize path similarly to the readlink utility. All components must exist.

-m, --canonicalize-missing
    Like above, but no components must exist.

-n, -no-newline
    Do not output the trailing newline. This is ignored if there are multiple inputs.

-q, -s, --quiet, --silent
    Most error messages are suppressed. The return failure code is still issued. This is the default.

-v, --verbose
    Do not suppress error messages.

-z, --zero
    By default, newlines are used to end each output line. With this flag, NUL is used instead.

--help
    Display a help message and exit.

--version
    Display version information and exit.

EXIT STATUS

SEE ALSO
readlink(3), realpath(1)

HISTORY
On FreeBSD this utility is a special invocation of stat(1) and first appeared in FreeBSD 4.10. This implementation is a part of chimerautils and is a special invocation of realpath(1).