LinuxCommandLibrary

unlink

TLDR

Remove file

$ unlink [file]
copy
Remove symlink
$ unlink [symlink]
copy

SYNOPSIS

unlink file

DESCRIPTION

unlink removes a single file. It calls the unlink syscall.
Single file only. No directories.
Atomic operation. System call.
No options. Simple interface.
Removes hard links. Decrements link count.

PARAMETERS

file

File to remove.
--help
Show help.
--version
Show version.

CAVEATS

Single file only. No recursive. Use rm for more features.

HISTORY

unlink is a standard Unix command that directly calls the unlink(2) system call to remove a directory entry.

SEE ALSO

rm(1), ln(1), unlink(2)

Copied to clipboard