Update December 2012
TAIL {outfile=} <wildspec> {/switches}
The TAIL command is similar to the eponymous UNIX command and is used to display or copy to another file the last N lines of a specified file (or wildcard list of files).
Switches
Switch |
Effect of Switch |
/D |
The delete switch causes TAIL to overwrite the existing outspec. |
L:## |
The lines switch causes TAIL to display or copy ## lines. The default is 20. As of A-Shell 1264, TAIL supports a UNIX-inspired variation of the /L:# switch, i.e. /L:+#, which causes the display/output to start at specified line #, rather than starting that many lines from the end. For example: .TAIL MYFILE.LST/L:+2 displays the entire file except for the first line. This can be useful for removing the first N lines from a file. For example, to remove the first line of a file, you could use the following command: .TAIL MYFILE.LST = MYFILE.LST/L:+2/D |
/Q |
The query switch causes TAIL to prompt for confirmation on each file. |
/? |
Writes switch listing and usage info to the screen. |
See the notes on HEAD for examples.
History
2012 December, A-Shell 1264: Add support for the /L:+# variation on the "L" switch, as noted above.