man-pages/man1/ln.1.html
2021-03-31 01:06:50 +01:00

160 lines
5.1 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML><HEAD><TITLE>Man page of LN</TITLE>
</HEAD><BODY>
<H1>LN</H1>
Section: User Commands (1)<BR>Updated: September 2019<BR><A HREF="#index">Index</A>
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
<A NAME="lbAB">&nbsp;</A>
<H2>NAME</H2>
ln - make links between files
<A NAME="lbAC">&nbsp;</A>
<H2>SYNOPSIS</H2>
<B>ln</B>
[<I>,OPTION/</I>]... [<I>,-T/</I>] <I>,TARGET LINK_NAME/</I>
<BR>
<B>ln</B>
[<I>,OPTION/</I>]... <I>,TARGET/</I>
<BR>
<B>ln</B>
[<I>,OPTION/</I>]... <I>,TARGET/</I>... <I>,DIRECTORY/</I>
<BR>
<B>ln</B>
[<I>,OPTION/</I>]... <I>,-t DIRECTORY TARGET/</I>...
<A NAME="lbAD">&nbsp;</A>
<H2>DESCRIPTION</H2>
<P>
In the 1st form, create a link to TARGET with the name LINK_NAME.
In the 2nd form, create a link to TARGET in the current directory.
In the 3rd and 4th forms, create links to each TARGET in DIRECTORY.
Create hard links by default, symbolic links with <B>--symbolic</B>.
By default, each destination (name of new link) should not already exist.
When creating hard links, each TARGET must exist. Symbolic links
can hold arbitrary text; if later resolved, a relative link is
interpreted in relation to its parent directory.
<P>
Mandatory arguments to long options are mandatory for short options too.
<DL COMPACT>
<DT id="1"><B>--backup</B>[=<I>,CONTROL/</I>]<DD>
make a backup of each existing destination file
<DT id="2"><B>-b</B><DD>
like <B>--backup</B> but does not accept an argument
<DT id="3"><B>-d</B>, <B>-F</B>, <B>--directory</B><DD>
allow the superuser to attempt to hard link
directories (note: will probably fail due to
system restrictions, even for the superuser)
<DT id="4"><B>-f</B>, <B>--force</B><DD>
remove existing destination files
<DT id="5"><B>-i</B>, <B>--interactive</B><DD>
prompt whether to remove destinations
<DT id="6"><B>-L</B>, <B>--logical</B><DD>
dereference TARGETs that are symbolic links
<DT id="7"><B>-n</B>, <B>--no-dereference</B><DD>
treat LINK_NAME as a normal file if
it is a symbolic link to a directory
<DT id="8"><B>-P</B>, <B>--physical</B><DD>
make hard links directly to symbolic links
<DT id="9"><B>-r</B>, <B>--relative</B><DD>
create symbolic links relative to link location
<DT id="10"><B>-s</B>, <B>--symbolic</B><DD>
make symbolic links instead of hard links
<DT id="11"><B>-S</B>, <B>--suffix</B>=<I>,SUFFIX/</I><DD>
override the usual backup suffix
<DT id="12"><B>-t</B>, <B>--target-directory</B>=<I>,DIRECTORY/</I><DD>
specify the DIRECTORY in which to create
the links
<DT id="13"><B>-T</B>, <B>--no-target-directory</B><DD>
treat LINK_NAME as a normal file always
<DT id="14"><B>-v</B>, <B>--verbose</B><DD>
print name of each linked file
<DT id="15"><B>--help</B><DD>
display this help and exit
<DT id="16"><B>--version</B><DD>
output version information and exit
</DL>
<P>
The backup suffix is '~', unless set with <B>--suffix</B> or SIMPLE_BACKUP_SUFFIX.
The version control method may be selected via the <B>--backup</B> option or through
the VERSION_CONTROL environment variable. Here are the values:
<DL COMPACT>
<DT id="17">none, off<DD>
never make backups (even if <B>--backup</B> is given)
<DT id="18">numbered, t<DD>
make numbered backups
<DT id="19">existing, nil<DD>
numbered if numbered backups exist, simple otherwise
<DT id="20">simple, never<DD>
always make simple backups
</DL>
<P>
Using <B>-s</B> ignores <B>-L</B> and <B>-P</B>. Otherwise, the last option specified controls
behavior when a TARGET is a symbolic link, defaulting to <B>-P</B>.
<A NAME="lbAE">&nbsp;</A>
<H2>AUTHOR</H2>
Written by Mike Parker and David MacKenzie.
<A NAME="lbAF">&nbsp;</A>
<H2>REPORTING BUGS</H2>
GNU coreutils online help: &lt;<A HREF="https://www.gnu.org/software/coreutils/">https://www.gnu.org/software/coreutils/</A>&gt;
<BR>
Report ln translation bugs to &lt;<A HREF="https://translationproject.org/team/">https://translationproject.org/team/</A>&gt;
<A NAME="lbAG">&nbsp;</A>
<H2>COPYRIGHT</H2>
Copyright &#169; 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later &lt;<A HREF="https://gnu.org/licenses/gpl.html">https://gnu.org/licenses/gpl.html</A>&gt;.
<BR>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
<A NAME="lbAH">&nbsp;</A>
<H2>SEE ALSO</H2>
<A HREF="/cgi-bin/man/man2html?2+link">link</A>(2), <A HREF="/cgi-bin/man/man2html?2+symlink">symlink</A>(2)
<P>
<BR>
Full documentation at: &lt;<A HREF="https://www.gnu.org/software/coreutils/ln">https://www.gnu.org/software/coreutils/ln</A>&gt;
<BR>
or available locally via: info '(coreutils) ln invocation'
<P>
<HR>
<A NAME="index">&nbsp;</A><H2>Index</H2>
<DL>
<DT id="21"><A HREF="#lbAB">NAME</A><DD>
<DT id="22"><A HREF="#lbAC">SYNOPSIS</A><DD>
<DT id="23"><A HREF="#lbAD">DESCRIPTION</A><DD>
<DT id="24"><A HREF="#lbAE">AUTHOR</A><DD>
<DT id="25"><A HREF="#lbAF">REPORTING BUGS</A><DD>
<DT id="26"><A HREF="#lbAG">COPYRIGHT</A><DD>
<DT id="27"><A HREF="#lbAH">SEE ALSO</A><DD>
</DL>
<HR>
This document was created by
<A HREF="/cgi-bin/man/man2html">man2html</A>,
using the manual pages.<BR>
Time: 00:05:18 GMT, March 31, 2021
</BODY>
</HTML>