6.B: The tail Command | 6: Viewing | 6: Viewing |
The more command writes your file onto the screen one page at a time. This means that after each page, it stops and waits for you to tell it what to do (it may also print the name of the file and the percent of the file it has read through, or maybe the prompt more).
Pressing the [space] bar brings up another page, and so on till you reach the file's end. To scroll through the file one line at a time, press the [return] or [enter] key in place of the [space] bar. To quit before reaching the end of the file, press the q key.
To see more in action, try:
> more ~/README.first
One useful application of the more command is to
regulate the output of some command which otherwise would zip by you
before you get a chance to read it. To do this, you use a "pipe"
|
which pipes the output of one command into the input of
another.
For example, here we list all the files in a large directory with
the output of the ls command being piped (|
) to
more:
> ls -a | more
> man more
If the file is very short you may wish to use the cat command instead. To see cat in action try
> cat area.f