Name

nl [man page] - number lines of files

Synopsis

nl [OPTION]... [FILE]... 

Frequently used options

-b, --body-numbering=STYLE
use STYLE for numbering body lines
-f, --footer-numbering=STYLE
use STYLE for numbering footer lines
-h, --header-numbering=STYLE
use STYLE for numbering header lines

Examples

$ echo -e "one\ntwo\nthree\nfour\nfive\n\nsix" > file 

nl - create a sample file

$ nl file 

nl - add line numbers

ARE YOU LOOKING FOR A LINUX JOB?
Submit your RESUME, create a JOB ALERT or subscribe to RSS feed on LinuxCareers.com.
DO YOU NEED ADDITIONAL HELP?
Get extra help by visiting our LINUX FORUM or simply use comments below.

You may also be interested in: