Name

!

Synopsis

[address] !command

Execute Unix command in a shell. If address is specified, use the lines contained in address as standard input to command, and replace the lines with the output and error output. (This is called filtering the text through the command.)

Examples

:!ls                List files in the current directory
:11,20!sort -fSort lines 11–20 of current file

Get Unix in a Nutshell, 4th Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.