←  linux commands

Views:

head command

The head command is used to output first lines of a file.

Syntax: head [options] file

Example:

head main.js
head-output

Options:

-n Prints first n lines of a file.

Example:

head -n 3 main.js
head-n-output