sbase/readlink.1

35 lines
791 B
Groff
Raw Normal View History

2015-01-30 22:34:36 +00:00
.Dd January 30, 2015
.Dt READLINK 1
2015-01-30 22:34:36 +00:00
.Os
.Sh NAME
.Nm readlink
.Nd print value of a symbolic link or canonical file name
.Sh SYNOPSIS
.Nm
.Op Fl fn
.Ar file
.Sh DESCRIPTION
The
.Nm
utility when invoked with the pathname of a symbolic link as
its argument dereferences the symbolic link and prints the name of the target
on standard output. If the
.Fl f
option is not specified and
.Nm
is
invoked with an argument other than the pathname of a symbolic link, it
exits with a nonzero exit code without printing anything.
2015-01-30 22:34:36 +00:00
.Sh OPTIONS
.Bl -tag -width Ds
.It Fl f
Canonicalize by following every symlink in every component of the
given path recursively. The argument does not need to be a symbolic
link.
2015-01-30 22:34:36 +00:00
.It Fl n
Do not output the trailing newline.
2015-01-30 22:34:36 +00:00
.El
.Sh SEE ALSO
.Xr readlink 2 ,
.Xr realpath 3