MIDDLE v1.31 - copy middle part of text file
Documentation revised 21 Oct 00 - Copyright (c) 1996-2000 by Rune Berg. TextTools Freeware.

Contents:


Usage Top || Next

middle [log logfile] [option] m n [infile] [to outfile]

See Understanding The Usage Section for details.


Description Top || Previous || Next

middle copies infile to outfile, except the m first and the n last lines.

If infile has m+n or fewer lines, outfile will be empty.

m and n must be in the range 0..2147483647.

If you don't specify infile, middle reads from standard input.
If you don't specify outfile, middle writes to standard output.
If you don't specify logfile, middle writes error messages to standard error.


Example Top || Previous || Next

The command:

      middle 3 5 mydata.txt

applied to file "mydata.txt" containing:

      Jan 7800
      Feb 1200
      Mar 19000
      Apr 7600
      May 21000
      Jun 8000
      Jul 9000
      Aug 60000
      Sep 55000
      Oct 3500
      Nov 7600
      Dec 32000

prints the following to the screen:

      Apr 7600
      May 21000
      Jun 8000
      Jul 9000


Options Top || Previous || Next

middle recognizes the following command line options:


Limitations Top || Previous || Next

middle runs out of memory if the specified 'middle portion' is very large.


Return Codes Top || Previous || Next

middle returns with one of the following codes ("error levels"):

For more details, see TextTools General Features.


Version History Top || Previous

These are the released versions of middle:

End of document