bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#8231: Bug in the linux command: tail


From: Eric Blake
Subject: bug#8231: Bug in the linux command: tail
Date: Fri, 11 Mar 2011 13:53:27 -0700
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.13) Gecko/20101209 Fedora/3.1.7-0.35.b3pre.fc14 Lightning/1.0b3pre Mnenhy/0.8.3 Thunderbird/3.1.7

On 03/11/2011 01:29 PM, Roger N. Clark wrote:
>> Basically, POSIX 2001 and newer does _not_ require -3 to be parsed as a
>> valid option (rather, the POSIX spelling is -n -3), so GNU coreutils is
>> supporting -3 as an extension.
>>
>> Then I looked at the actual POSIX 2008 wording:
>> http://pubs.opengroup.org/onlinepubs/9699919799/utilities/tail.html
>>
>>     tail [-f] [-c number|-n number] [file]

> 
> Thank you for the quick reply.  I'm fine with needing to say -n -3.

Yes, POSIX is clear that '-n -3' and '-n 3' have the same meaning as the
traditional '-3'.

> Perhaps the man page needs to be clearer, so should be changed from the
> current:
> 
>        -n, --lines=N
>               output the last N lines, instead of the last 10

That's not current.  Coreutils 8.10 is the latest release, and the man
page from that version (as well as 'tail --help', from which the man
page is generated) states:

      -n, --lines=K
              output the last K lines, instead of the last 10; or use -n
+K to
              output lines starting with the Kth

-- 
Eric Blake   address@hidden    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]