Linux Today: Linux News On Internet Time.

More on LinuxToday

developerWorks: Reading Text Streams in Chunks With head and tail

Nov 26, 2002, 02:30 (0 Talkback[s])
(Other stories by Jacek Artymiak)


Desktop-as-a-Service Designed for Any Cloud ? Nutanix Frame

Suppose you want to process only a part of some file, say a few lines from the start or end of it. What can you do? Use either head (which sends the first 10 lines to the standard output) or tail (which sends the last 10 lines to the standard output).

"You can change the number of lines that these commands send to their standard output with the -n option (of course, your results will vary depending on the contents of your XF86Config file).."

Complete Story

Related Stories: