Mike's Script Archive : slice
slice - Grab a slice from a file defined by a line range
NAME
slice - Grab a slice from a file defined by a line range
slice
SYNOPSIS
slice from_line to_line [file]
from_line: Line number to start the slice with
to_line: Line number to end the slice with
file: File name
slice opens the given file or STDIN and prints the lines starting from from_line
and ending at to_line
.
EXAMPLES
$ slice 1 3 /etc/passwd
... prints the first three lines of /etc/passwd.
$ cat /etc/passwd | slice 5 10
... prints lines 5 to 10 of /etc/passwd.
Copyright 2002 by Mike Schilli, all rights reserved.
This program is free software, you can redistribute it and/or
modify it under the same terms as Perl itself.
2002, Mike Schilli <m@perlmeister.com >