Nl
Jump to navigation
Jump to search
The nl command numbers the lines in its input files.
In its simplest invocation, nl concatenates the contents of the file names given as arguments to standard output, with sequential line numbers. A file name of '-' (a single hyphen) as with most Unix commands, means to read from standard input.
A simple example:
$ cat > sample first line second line ^D $ nl sample 1 first line 2 second line $
This article is a stub and needs to be finished. Plunge forward and help it grow!
Provided by
Most (all?) Linux distributions incorporate this from the GNU Coreutils: and use its man page
Related Commands
These all relate to the output or processing of entire files