Download man pages section 1: User Commands
Transcript
tail(1) The origin for counting is 1; that is, -c+1 represents the first byte of the file, -c−1 the last. -n number OPERANDS The following operand is supported: file USAGE EXAMPLES Equivalent to -cnumber, except the starting location in the file is measured in lines instead of bytes. The origin for counting is 1. That is, -n+1 represents the first line of the file, -n−1 the last. A path name of an input file. If no file operands are specified, the standard input will be used. See largefile(5) for the description of the behavior of tail when encountering files greater than or equal to 2 Gbyte ( 231 bytes). EXAMPLE 1 Using the tail Command The following command will print the last ten lines of the file fred, followed by any lines that are appended to fred between the time tail is initiated and killed. example% tail -f fred The next command will print the last 15 bytes of the file fred, followed by any lines that are appended to fred between the time tail is initiated and killed: example% tail -15cf fred ENVIRONMENT VARIABLES EXIT STATUS ATTRIBUTES See environ(5) for descriptions of the following environment variables that affect the execution of tail: LANG, LC_ALL, LC_CTYPE, LC_MESSAGES, and NLSPATH. The following exit values are returned: 0 Successful completion. >0 An error occurred. See attributes(5) for descriptions of the following attributes: /usr/bin/tail ATTRIBUTE TYPE ATTRIBUTE VALUE Availability SUNWcsu CSI Enabled /usr/xpg4/bin/tail ATTRIBUTE TYPE ATTRIBUTE VALUE Availability SUNWxcu4 CSI Enabled Interface Stability Standard User Commands 1507