| LN(1) | General Commands Manual | LN(1) |
ln — create hard
links and symbolic links
ln |
[-fnv]
[-L|-P]
-T source
target |
ln |
[-fnv]
[-L|-P]
source... [target] |
ln |
[-fnv] -Ts
reference target |
ln |
[-fnv] -s
reference... [target] |
ln create links at
target for each given source or
reference.
Unless -T is passed, when
target is an existing directory or multiple
source or reference are given,
ln will create links into
target. If target is
unspecified, then it is set to the current directory, as if "."
would have been passed.
Should be noted that unlike commands like cp(1), reference is kept as is and therefore is always relative to target rather than the current directory.
-f-L-n-P-s-T-vThe ln utility exits 0 on success,
and >0 if an error occurs.
ln should be compliant with the IEEE Std
1003.1-2024 (“POSIX.1”) specification. The
-n, -T, and
-v options are extensions. Support for unspecified
target is an extension.
Haelwenn (lanodan) Monnier <contact+utils@hacktivis.me>
| January 22, 2025 | Linux |